Preheat the oven to 350°F. Butter and flour two 9-inch round cake pans, or lightly spray with baking spray, and line the bottoms with parchment paper. (I prefer to bake these cake layers without baking strips wrapped around the pan.)
In a large bowl, sift together the flour, baking soda, baking powder, and salt.
Add the butter to the bowl of a stand mixer with the paddle attachment (or a large bowl with a handheld mixer). Beat on medium speed until creamy.
In a medium bowl, whisk together the cocoa powder and oil. Add it to the butter along with the granulated and brown sugars. Beat on medium speed until very light and fluffy, about 5 minutes, stopping to scrape down the bowl a few times during mixing. With the mixer running, add the eggs, one at a time, beating well after each addition. Stop to scrape down the bowl as needed throughout mixing. Beat in the vanilla.
With the mixer on low speed, add a third of the flour mixture followed by half of the milk and half of the sour cream. Continue alternating with another third of the flour, the rest of the milk and sour cream, and the remaining flour. Scrape down the bowl and mix once more if needed to incorporate all of the flour. Add the hot coffee and carefully whisk together until well combined. Pour the batter into the prepared cake pans.
Bake for 40 to 45 minutes or until the cakes are starting to pull away from the sides of the pans and the center springs back when gently pressed. Let the cakes cool completely in the pans. Carefully invert the cakes and remove the parchment paper. (The cakes are very tender and delicate so be gentle.)
For the Assembly:
Place a cake layer on a cake stand, spread about ¾ cup of frosting over the top. Place with the remaining cake layer on top. Spread the remaining frosting all over the outside of the cake. The assembled cake can be covered and stored at room temperature for up to 5 days.
Video
Notes
Don’t skip sifting the cocoa powder. Sifting helps prevent lumps in the mixture when combined with the oil.
Avoid over-mixing the batter. Stop when you see the streaks of flour just disappear. You are going to add the hot coffee last, so any last bits of flour will get mixed in along with the coffee. If you continue mixing it for too long, you risk over-developing the gluten in the batter, leading to a tough, dry, and dense Devil’s food cake.
The cakes will shrink somewhat as they cool. This is normal! They should evenly settle and produce a flat top as they cool.
Serving a crowd? Check out my tricks for cutting a round cake to serve more people!