This Rainbow Cake recipe is moist, tender, and beyond stunning with its six different colored cake layers! The brightly colored cake will be the star of the show!
Preheat the oven to 350F. Grease two or three 8-inch round cake pans with baking spray or butter. Line the bottoms with parchment paper.
In a large mixing bowl, whisk together the flour, sugar, baking powder, baking soda, and salt.
In another large mixing bowl, combine the eggs, vegetable oil, milk, and vanilla. Whisk until well combined. Pour into the flour mixture and whisk until combined.
Divide the batter among 6 mixing bowls. Color each batter with food coloring to make red, orange, yellow, green, blue, and purple batters. Pour a single color batter into each cake pan. Place the remaining batter bowls in the fridge until ready to bake. (This helps to stop the baking powder from reacting while waiting to bake.)
Bake for 20 minutes or until a toothpick inserted into the center comes out clean. Let the cakes cool for 10 minutes in the pan, then remove and finish cooling on a wire rack. Wash the pans, grease and line with parchment paper again, and bake the remaining batters.
For the Buttercream:
In a large mixing bowl or the bowl of a stand mixer fitted with the whisk attachment, beat the butter and salt on medium speed until very fluffy and pale, about 5 minutes.
With the mixer on low speed, gradually add the confectioners’ sugar a cup at a time, adding a tablespoon of cream at a time throughout mixing. Stop and scrape down the bowl occasionally during mixing. Once all of the sugar is added, beat in the vanilla and add additional cream if the frosting feels grainy when rubbed between your fingers. Increase the speed to medium-low and beat until light and fluffy, about 1 minute.
For the Assembly:
Remove the parchment paper from the cake layers. Place the purple layer on a cake plate and spread ½ cup of frosting over the top. Place the blue layer on top and spread another ½ cup of frosting on top. Repeat with the remaining cake layers in the order of green, yellow, orange, and red. Spread the remaining frosting all over the outside of the cake. Chill the cake for at least 1 hour before serving. Leftover cake should be covered and can be stored at room temperature for up to 3 days.
Video
Notes
If the tops of your rainbow cake layers are domed, then use a serrated knife to cut off the top of the domes so you can stack them evenly. Alternatively, use cake strips to help your cake layers come out evenly. Cake strips work by keeping the outside edge of the pan cooler to ensure that the entire cake rises at the same rate, preventing a dome from forming in the middle. If you don’t want to buy cake strips, then see my post on how to DIY cake strips.
I highly recommend using a scale to measure your flour, as it’s the most accurate method. If you don’t have a scale, fluff your flour with a spoon and spoon it into your cups before leveling it off with a knife. Fluffing the flour and spooning it into a measuring cup prevents you from overpacking it.
Make sure to allow the cake layers to cool before you add the buttercream.
The longer you chill the rainbow cake, the better the buttercream will stick to the cake layers.
Make sure the butter is room temperature before you cream it, as cold butter will lead to lumpy buttercream.
Avoid over-mixing the batter as you risk over-developing the gluten leading to a tough, dry, and dense cake.