Preheat your oven to 350°F / 180°C (160°C fan-assisted) and grease an 8-inch cake pan.
In a large bowl, sift the dry ingredients, including the flour, sugar, cocoa powder, baking powder, and salt. Whisk everything together.
In a separate bowl, combine all the wet ingredients, except the hot water, which includes the eggs, milk, vegetable oil and vanilla. Whisk together lightly until smooth.
Pour the wet ingredients into the dry and whisk until everything is combined and there are no lumps.
In a small bowl or a glass, combine the hot water with the espresso powder and mix until completely dissolved. Pour into the cake batter and mix until combined.
Pour the batter into the prepared cake pan and bake for 25-30 minutes, or until a skewer inserted comes out clean. Let it cool completely in the pan.
Once cooled, use a cake leveler or serrated knife to cut off any dome on top, then slice cake in half lengthwise so you have two thinner layers.
Place a cake ring on top of a cake board or serving plate and place one of the layers of cake on the bottom. Set aside until the mousse is ready.
Make the Chocolate Mousse
Put egg yolks in a bowl with the sugar and cornstarch and whisk until they become slightly thick and pale.
Pour 1 cup of the heavy cream into a saucepan and warm over medium-low heat until it is scalding hot. This means it is giving off steam and there are tiny bubbles appearing on the surface. Don't let it boil.(Make sure you keep the remaining heavy cream in the fridge so it is cold enough to whip later).
Drizzle a little of the hot cream into the egg yolks and whisk it in. Keep drizzling a little more, whisking the whole time, until all the cream is added. Then pour the entire mixture back into the saucepan and return to the heat.
Heat the mixture, whisking constantly (but not vigorously - just enough to keep it moving and avoid burning) until it begins to thicken and boil. Let it boil for about a minute.
Remove from the heat and mix in the vanilla extract and salt.
Divide the mixture evenly between two bowls, then stir the dark chocolate into one and the white chocolate into the other. Mix each bowl until the chocolate has completely melted.
In a separate bowl, whip up the reserved heavy cream until medium peaks form. By the time you have whipped the cream, the two chocolate mousse bases should have cooled to room temperature. If they are still warm, let them cool completely, then split the whipped cream evenly between the two chocolate mousse mixtures and fold it in gently until completely combined.
Pour the dark chocolate mousse on top of the cake layer in your dessert ring and smooth it out with a spatula.
Pour the white chocolate mousse on top and smooth it out in the same way. The dark chocolate will be a lot firmer than the white chocolate, so you should be able to pour the white chocolate mousse on top without them mixing together. If your dark chocolate is still very liquid, put it in the fridge for a few minutes after pouring it onto the cake before adding the white chocolate layer.
Put the entire cake in the fridge for 30 minutes. After 30 minutes, add the second cake layer on top, then return to the fridge to set for at least 4 hours, preferably overnight.
Make the Chocolate Ganache
Once the cake has been chilling for at least 4 hours, remove it from the fridge and release it from the cake ring. Return to the fridge while you make your ganache.
Chop your chocolate finely and place it in a bowl.
Heat the cream on medium heat, just until scalding (tiny bubbles just starting to form). Don't let it boil. Remove from the heat and pour the cream over the chocolate. Let it sit for a minute.
Mix the cream and the chocolate together until completely melted, glossy and smooth. Let it cool completely to room temperature. It should be thick enough that it won't just run off the side of the cake, but thin enough to spread out into a nice smooth layer on top of the cake.
Spread the ganache on top of the cake and use a spatula or knife to spread it out to the edges.
Decorate with sprinkles or chocolate shavings.
Notes
I always recommend measuring your ingredients with a scale rather than with cups - it's very hard to be accurate when measuring with cups and incorrect quantities could mess up your entire bake! So, for best results, always use a scale. All my recipes provide measurements in both cups and grams so you can choose what works best for you.
EDIT - 8th November 2024:
After feedback from readers, I have made a few small tweaks to this recipe to help everyone have the best chance of success. The changes made were:
Increased the amount of white chocolate in the white chocolate mousse so it sets up better.
Adjusted the ratio of cream to chocolate in the chocolate ganache so it is less runny
Improved instructions to clarify how the cream is divided and used.
Improved the instructions for heating the cream properly so that the mousse thickens.
Thank you for all your feedback - I hope you love this improved version of the recipe even more!