This bright and cheerful rainbow cake features six cake layers enrobed in smooth Swiss buttercream.
I think this is the perfect celebration cake for all occasions! On the outside it seems like a boring vanilla white cake. But once you slice into it, you get this surprising happy pop of color and excitement.
Rainbow cakes are great for parties and gatherings. They’re an instant crowd-pleaser! The harmony of colors appeals to everyone, young and old alike. Best of all, you can easily customize the colors to your liking or swap in different flavors or fillings.
Ingredients
This cake recipe starts with a simple vanilla cake base. Butter and vanilla are the two main ingredients that flavor this cake. As such, it is vital to use fresh butter and high quality vanilla.
The cake base is made with egg whites to produce a white cake base that allows the different colors to shine. You will need the standard cake ingredients of: sugar, flour, baking powder, baking soda, milk, and sour cream.
Coloring Cake Layers
There are several ways to color the cake. Use soft gel paste food coloring to achieve the most vibrant colors. DO not use liquid food coloring. The batter will be too thin. It will not bake off properly.
This rainbow cake recipe was specifically created for artificial dye gel food colors.
- For vibrant colors: AmeriColor Soft Gel Paste Food Color in super red, lemon yellow, electric orange, electric green, electric blue, and royal purple.
- For neon colors: use Chefmaster Neon Liqua-gel food color in neon brite pink, neon brite orange, neon bright yellow, neon brite green, neon brite blue, and neon brite purple.
I have tested this recipe with food gels made with vegetable colorants (this India Tree color set). See results below.
Step-by-Step Instructions
Recipe Tip
Cake layers may be baked ahead of time. Cool to room temperature. Individually wrap the layers in plastic wrap. Store in the freeze for up to one month. Defrost at room temperature.
Cake Assembly
Serving Suggestions
Store assembled frosted cake in the fridge until ready to serve, up to three days in advance. Take note of any highly aromatic flavors in the fridge such as onions, garlic, fermented foods, or blue cheese that may seep into the cake.
Use a sharp knife to make clean cake slices. Wipe the blade between cuts to ensure clean lines.
A cold cake will be easier to slice. However, let the cake sit out for at least 15-30 minutes before serving for best flavor and texture. The buttercream and cake need time to soften.
Rainbow cake is delicious on it’s own! Make it even better with decorative garnishes such as fresh berries, cut fruit, or edible flowers. And of course, it’s wonderful with a scoop of ice cream on the side!
More Celebration Cake Recipes
- Coconut Confetti Cake
- Chocolate Butter Mochi Cake
- Birthday Cinnamon Roll Cake
- Funfetti Doughnut Cake
Rainbow Cake
Ingredients
Cake:
- 1 cup unsalted butter, (227 g), room temp
- 2 cups granulated sugar, (400 g)
- 5 large egg whites, (165 g) about โ cup, room temp, lightly whisked
- 1 ยฝ teaspoon high quality pure vanilla extract, or vanilla paste
- ยฝ cup sour cream, (120 g), room temp
- 3 cups all-purpose flour, (390 g)
- 1 Tablespoon baking powder, (12 g)
- 1 teaspoon baking soda, (5 g)
- ยฝ teaspoon kosher salt, or fine sea salt
- 1 cup whole milk, (227 g)
- soft gel paste food colors*, see notes
Swiss Buttercream:
- 6 large egg whites, (210 g), about 1 cup
- 1 ยฝ cup granulated sugar, (300 g)
- 2 cup unsalted butter, (454 g), sliced into tablespoons, softened
- ยฝ teaspoon kosher salt, or fine sea salt
- 1 teaspoon high quality pure vanilla extract, or vanilla bean paste
Instructions
- Preheat oven to 350โ. Gather as many 8-inch round cake pans as you can find. Butter and line the cake rounds with parchment paper rounds. Set aside.NOTE: You may bake the layers in batches if you don't have enough cake pans. Clean cake pans between baking.
- In a bowl of a stand mixer with the paddle attachment, cream butter. Add sugar and continue to cream until lighter in color. Slowly add egg whites to the butter on low-medium speed. Add vanilla and sour cream. Mix until thoroughly combined.
- In a medium bowl, whisk together flour, baking powder, baking soda and salt. Alternate adding flour mixture and milk to the creamed mixture. Add the flour in three additions, beginning and ending with the flour.
- Use a kitchen scale to weight cake batter. Take the weight and divide it by 6. (My total weight was 1530 grams. Divide by 6, it was 255 grams.) Measure out equal amounts of batter into 6 small bowls. Note: If you donโt have a scale, it was roughly 3/4 cup of batter into 6 bowls.
- Add food coloring to individual bowls. I used about 4-8 drops of coloring for each. Some colors required more gel than others to get the vibrant hues I wanted. Be sure to use food gels. Adding liquid food coloring will make your batter too runny and thin.
- Transfer colored batter to prepared cake pan. Bake for 13-15 minutes until cake is set. Let cool in pan for 3 minutes before unmolding and allowing to cool completely on the racks. Continue to bake off cakes until you have completed all six colors.
Buttercream:
- Whisk together egg whites and sugar in the bowl of stand mixer. Place bowl over a pot of simmering water to create a bain-marie or double boiler. Make sure the simmering water does not touch the bottom of the bowl. Whisk mixture until it reaches a temperature of 160ยฐF.*Alternatively, if you don't have a thermometer, heat the mixture until all the sugar has melted. Test this by dipping your pointer finger into the mixture and rubbing it against your thumb. The mixture should feel smooth. You should not be able to feel the granules of sugar.
- Return bowl to stand mixer. Using the whisk attachment, beat mixture at medium speed until it has cooled to room temperature (about 75-80ยฐF) and meringue has started to form.
- Reduce to low speed. Add butter one tablespoon at a time. Add salt and vanilla. Increase speed to medium-high and continue to beat until buttercream is light and fluffy.
Assembly:
- Place the purple layer of cake on a cake board. If desired, lightly soak cake layer with simple syrup (or other flavored syrup). Spread about 1/4 cup buttercream on cake.
- Repeat adding syrup and buttercream on remaining layers (blue, green, yellow, orange, and red).
- Spread a thin layer of buttercream around the sides of cake to seal in the crumbs (crumb coat). Place in the fridge and allow to chill for 15 minutes to set buttercream.
- Coat cake with final thicker layer of buttercream. Decorate cake as desired. Store cake in the fridge until ready to serve.
Notes
- For vibrant colors use AmeriColor Soft Gel Paste Food Color ย in super red, lemon yellow, electric orange, electric green, electric blue, and royal purple. Be sure to use food coloring GEL. ย Please do not use liquid food coloring. ย The batter will be too thin and not bake off properly.
- For neon colors use Chefmaster Neon Liqua-gel food color in neon brite pink, neon brite orange, neon bright yellow, neon brite green, neon brite blue, and neon brite purple.ย
- I have tested this recipe with food gels made with vegetable colorants. Unfortunately, the heat from baking chemically alters the colors, making them very muted.ย
- Recipe makes just enough buttercream to coat cake with a thin layer. If you have a heavy hand with frosting- I suggest doubling the buttercream recipe. Excess buttercream may be stored in the freezer for up to a month.ย
- If you add the butter when the meringue is too hot, it may melt and the buttercream may not emulsify. ย If this happens, place the mixing bowl in the freezer for a couple minutes to cool down the mixture. ย Once cooled, started whipping again.
- If the butter is too cold when added to the meringue, the buttercream may end up chunky. ย Use a torch to warm the bowl or place over a bain-maire to soften the butter.
Nutrition
Nutrition information is automatically calculated, so should only be used as an approximation.
Thanks for the awesome recipe! Was a hit for my daughter’s 5th birthday party!
You’re welcome! That’s wonderful to hear! :)
This cake did not rise. Tried it twice what a WASTE of eggs
Hi Sara, I’m sorry to hear that. I’ve made this cake numerous times without fail.
I made this cake for my friends whose kids had birthdays really close together. It was fabulous! I was worried because the batter was in such a thin layer in the pans. I ended up using egg whites from a carton since I needed it for both the cake and buttercream. It worked out just fine and the colors were vibrant. Everyone was impressed by both the rainbow as well as the taste of the cake. It was worth the effort.
That’s wonderful to hear! Thanks so much for trying out the recipe. I’m so glad everyone enjoyed it! :)
I haven’t made this cake yet, but I plan to. I need to feed a bunch of people, 30+ so I’m thinking of making 1.5X the recipe and baking it in a 10 inch pan. I was wondering if I could just use 3 whole eggs instead of whites only. I could see if you were not adding color to the cake, whites would keep the cake really white. Will whole eggs change it too much?
No, you cannot substitute 3 whole eggs in place of 3 egg whites. Egg whites are composed of water and protein, where as egg yolks are made of fat. Using whole eggs will greatly affect the resulting cake. I have never tried the recipe with whole eggs. That being said, if you’d like to give it a try, I’d love to hear how it turns out.
I really like this recipe! I’m making it for a friend’s surprise bridal shower. I made a test cake and it did not turn out well. One of the reasons, I realized, was because apparently I bought two 10-inch pans instead of two more 9-inch pans. But I noticed that even the 9-inch layers didn’t even fill the bottom of the pan. Any thoughts? Also, is the butter measurement correct for the frosting? That’s FOUR AND A HALF STICKS OF BUTTER. My girlfriend was the taste tester and thought it just tastes like butter, and she has a cold! The texture was originally like whipped cream until I chilled it. Is that right? It didn’t look as thick as in the picture.
Hi! I love your cake and what it represents! I am making the cake for my twins’ 1st birthday party. I’m not sure where I can buy the americolor soft gel paste or the vanilla paste in local stores, any suggestions? I am finding them online, but I can’t find the “royal purple” color at all. For the other colors it seems like I will have to buy them individually bc they don’t come in a package together. It ends up being kind of expensive. Any suggestions for that? Thank you!
Thanks Julie! I suggest looking for a cake supply/bakery speciality/restaurant supply store in your area. (If you live in the LA area I can give you some suggestions.) Sometimes well stocked craft stores like Michael’s carry gel paste. Michael’s doesn’t sell AmeriColor, but they do have other brands of gel paste available. You don’t have to use the exact colors I have listed. If you can’t find certain colors, you can also mix colors together to get the color you need. I hope that helps! :)
I have been asked to bake a cake for a good friend’s small wedding. I would love to surprise them with the rainbow cake. One question though, and it may be a silly one…do think there is any worry about the colors staining teeth for pictures? They have asked for white cake and white frosting for that exact reason…
Hi Aimee. Yes, I would NOT suggest making this for a wedding. The dyes from the cake will likely turn your tongue a different color. I usually reserve this cake for children’s parties and birthdays. I’d stick to the white cake for the wedding :) Hope that helps!
Can’t wait to make this for my daughters 5th birthday! Can I get this soft gel paste just at my local grocer or is it something I would find in a specialty store? Thank you for sharing your recipe.
Happy early birthday to your daughter! I suggest going to a specialty store to find the soft gel paste. Several craft stores also carry it and it is readily available online.
I never thought I’d cry when reading a cake recipe, it is just so well written, thank you. Can’t wait to try to make the cake!
Thank you so much Sherry! Happy baking! :)
Horrible did not work AT ALL
I’m sorry to hear that! I’ve used this recipe several times with good results.