Yellow Cake with Chocolate Icing Recipe from Scratch
In this article
Time: 1 hr 15 min · Serves: 12 · The key step: Creaming the butter and sugar thoroughly to ensure a light, airy crumb.
This scratch-made yellow cake features a tender, buttery crumb and a rich, silky chocolate icing. It is a classic dessert suitable for birthdays, afternoon tea, or any occasion requiring a reliable, homemade sponge. The cake relies on real butter and eggs for flavor, while the icing provides a deep cocoa contrast.
Scale Your Cake Batch
Adjusting the recipe size depends on the number of guests or the pan dimensions you choose to use. Using the correct ratios prevents the cake from being too dense or too fragile.
| Batch Size | Yield | Pan Suggestion |
|---|---|---|
| Half Batch | 6 servings | One 6-inch (15 cm) round pan |
| Full Batch | 12 servings | Two 8-inch (20 cm) round pans or one 9x13-inch (23x33 cm) pan |
| Double Batch | 24 servings | Three 8-inch (20 cm) round pans or two 9x13-inch (23x33 cm) pans |
Gather the Ingredients for the Cake and Icing
For the Yellow Cake
- 2 cups (250 g) all-purpose flour
- 1 ½ tsp (7.5 ml) baking powder
- ½ tsp (2.5 ml) salt
- ¾ cup (170 g) unsalted butter, softened to room temperature
- 1 cup (200 g) granulated sugar
- 3 large eggs, room temperature
- 1 tsp (5 ml) vanilla extract
- 1 cup (240 ml) whole milk, room temperature
For the Chocolate Icing
- ½ cup (115 g) unsalted butter, softened
- 2 cups (250 g) powdered sugar, sifted
- ⅓ cup (30 g) unsweetened cocoa powder, sifted
- ¼ cup (60 ml) whole milk or heavy cream
- 1 tsp (5 ml) vanilla extract
- Pinch of salt
Prepare the Pans and Preheat the Oven
Preheat your oven to 350°F (175°C). For an even bake, ensure your oven rack is in the center position. Prepare two 8-inch (20 cm) round cake pans by greasing them with butter or cooking spray and dusting with a light coating of flour. Tap out any excess flour so it does not create a thick, dry layer on the cake surface. If using a 9x13-inch (23x33 cm) pan, grease the bottom and sides thoroughly.
Mix the Batter Using the Creaming Method
- Whisk together the flour, baking powder, and salt in a medium bowl until no lumps remain. Set this dry mixture aside.
- In a large mixing bowl, beat the softened butter and granulated sugar together using a hand mixer or stand mixer on medium-high speed. Continue for about 3-5 minutes until the mixture looks pale and fluffy. This step incorporates air, which is essential for a light yellow cake.
- Add the eggs one at a time, beating well after each addition. Scrape down the sides of the bowl with a spatula to ensure all ingredients are incorporated. Stir in the vanilla extract.
- Reduce the mixer speed to low. Add the flour mixture in three parts, alternating with the milk. Start with one-third of the flour, then half of the milk, then another third of the flour, the rest of the milk, and finish with the last of the flour. Mix only until the flour streaks disappear. Overmixing at this stage will develop gluten and result in a tough, bread-like texture.
Bake the Cake Until Set
- Divide the batter evenly between the prepared pans. Use a kitchen scale if you want exact equality between the layers.
- Place the pans in the preheated oven and bake for 30-35 minutes. To check for doneness, insert a wooden toothpick into the center of the cake; it should come out clean or with just a few moist crumbs. The cake should also feel springy to the touch and begin to pull slightly away from the edges of the pan.
- Remove the pans from the oven and let them sit on a wire rack for 10 minutes. Run a thin knife around the edge of the pans to loosen the cake, then carefully invert them onto the wire rack to cool completely. A warm cake will melt the icing, so ensure the layers reach room temperature before proceeding.
Whip the Chocolate Icing
- In a clean bowl, beat the softened butter for 2 minutes until creamy.
- Add the sifted powdered sugar and sifted cocoa powder. Mix on low speed until the sugar is mostly incorporated to avoid a cloud of dust.
- Increase the speed to medium and add the milk (or heavy cream), vanilla extract, and salt. Beat for another 2-3 minutes until the icing is smooth and spreadable. If the icing is too thin, add more powdered sugar 1 tablespoon at a time. If it is too stiff, add more milk 1 teaspoon at a time.
Assemble and Frost the Layers
Place one cake layer on a serving plate. Spread about one-third of the chocolate icing evenly over the top. Place the second cake layer on top of the first. Use the remaining icing to cover the top of the cake and the sides. Use an offset spatula to smooth the icing or a spoon to create decorative swirls. If you are making a 9x13-inch cake, simply spread the icing over the entire top surface once the cake has cooled.
Adjust the Flavor and Texture
You can modify the base recipe to suit different preferences without starting from scratch. Small changes to the fats or liquids will alter the final result.
Swap the Fat Source
Replace the unsalted butter in the cake with vegetable oil for a moister, denser crumb. Note that oil does not provide the same flavor profile as butter, so the cake will taste less rich. If using oil, use 3/4 cup (180 ml) instead of 3/4 cup (170 g) of butter.
Change the Liquid
Substitute the whole milk with buttermilk to add a slight tang and a more tender texture. If using buttermilk, use the same volume (1 cup/240 ml). The acidity in buttermilk reacts with the baking powder to create a more lifted sponge.
Modify the Icing Intensity
For a darker, more intense chocolate flavor, replace the unsweetened cocoa powder with high-quality Dutch-processed cocoa. This will result in a smoother, less acidic icing. For a lighter chocolate taste, reduce the cocoa powder to 2 tablespoons (15 g) and increase the powdered sugar by 1/2 cup (60 g).
Store the Cake Safely
Proper storage prevents the cake from drying out and keeps the icing from becoming unpleasantly hard or greasy. Because this cake contains dairy and eggs, it must be handled according to food safety standards.
Place the cake in an airtight container or cover the serving plate tightly with plastic wrap. Store the cake in the refrigerator. Refrigerated cake stays fresh for about 3-4 days. If you need to store it for longer, you can wrap individual slices tightly in plastic wrap and place them in a freezer bag; they will keep for up to 3 months. When you are ready to eat, let the cake sit at room temperature for about 30 minutes to allow the butter in the sponge and icing to soften slightly.
When reheating leftovers, if you choose to warm a slice, use a microwave on low power for 10-15 seconds. Ensure any reheated portion reaches a safe temperature of 165°F (74°C) if it has been sitting out, though for a simple cake, the primary concern is texture. Never leave the cake out on the counter for more than 2 hours, especially in environments above 90°F (32°C).
Common Cake Baking Questions
Why is my cake dense instead of fluffy?
Density usually stems from two issues: improper creaming or overmixing. If the butter and sugar are not beaten until pale and airy, there will not be enough air pockets to lift the flour. Additionally, once the flour is added, mixing too long develops gluten, which creates a tough, heavy structure rather than a light crumb.
Can I make the icing ahead of time?
Yes, the chocolate icing can be made up to 2 days in advance. Store it in an airtight container in the refrigerator. Because the butter will firm up when cold, you will need to let it sit at room temperature for about 30-60 minutes and then give it a quick whip with a mixer before spreading it on the cake.
What if my cake sinks in the middle?
A sunken center often means the oven temperature was too high, causing the cake to rise too quickly before the structure was set, or that the baking powder was expired. Ensure your baking powder is fresh and avoid opening the oven door during the first 20 minutes of baking, as the sudden drop in temperature can cause a collapse.