Combine dry ingredients: In a medium saucepan, whisk together the sugar, cocoa powder, cornstarch, and salt.
¾ cup granulated sugar, ¼ cup unsweetened cocoa powder, 3 tablespoons cornstarch, ½ teaspoon salt
Add liquids: Gradually whisk in the milk and heavy cream until smooth. Place the saucepan over medium heat.
2 cups whole milk, ½ cup heavy cream
Cook the pudding: Stir constantly until the mixture thickens and begins to bubble slightly, about 6–8 minutes. Reduce the heat to low and continue stirring for another 1–2 minutes.
Temper the egg yolks: In a small bowl, lightly whisk the egg yolks. Slowly add a a tablespoon at a time of the hot pudding mixture to the yolks, whisking constantly to avoid scrambling them.
2 large egg yolks
Incorporate yolks: Pour the tempered egg yolks back into the saucepan, whisking to combine. Cook for another 1–2 minutes until the pudding thickens a little more.
Add chocolate and vanilla: Remove the saucepan from the heat. Stir in the chopped chocolate and vanilla extract until smooth and fully melted.
4 ounces bittersweet chocolate, 1 teaspoon pure vanilla extract
Cool and set: Pour the pudding into individual serving dishes or a large bowl. Press plastic wrap directly onto the surface of the pudding to prevent a skin from forming. Refrigerate for at least 2 hours.
Serve: Top with whipped cream, fresh berries, or chocolate shavings if desired. Enjoy!