Rainbow layer cake
Rainbow layer cake is made of six egg-white butter cake layers, each a different color from red, orange and yellow through green, blue and purple, stacked and covered in smooth white buttercream. It looks simple on the outside, but cut into it and a vivid band of colors appears, which is why it's such a favorite for birthday parties.
- Difficulty
- Hard
- Prep
- 1 hr
- Cook
- 40 min
- Rising or chilling
- 2 hr
- Total time
- 3 hr 40 min
- Method
- Oven-baked

Ingredients
Egg white cake batter
Vanilla buttercream
Decoration
Instructions
Step 1
Preheat the oven to 175°C, line two or three 20 cm round cake pans with parchment paper and butter the sides. You'll bake the six layers in several batches, so having more pans ready saves time. The pans are ready when the paper lies flat and the sides are glossy with butter.
Step 2
Put 450 g cake flour, 400 g granulated sugar, 14 g baking powder and 4 g salt in the bowl of a stand mixer and mix on low speed for about thirty seconds. Mixing the dry ingredients first spreads the baking powder and salt evenly through this big batch of batter. The mixture is ready when it's uniform with no lumps of sugar or flour.
Step 3
Cut 225 g softened unsalted butter into small pieces, drop them into the bowl a few at a time with the mixer running on low and mix for about two minutes. This reverse creaming method coats the flour in fat, limiting gluten so the crumb is fine and tender. The mixture is ready when it looks like damp sand with no large pieces of butter left.
Step 4
Whisk 240 g egg whites, 360 g whole milk, 60 g vegetable oil and 10 g vanilla extract together in a pitcher, pour half into the bowl and beat on medium speed for about a minute, then pour in the rest and beat for thirty seconds more. Adding the liquid in two stages builds good structure in the batter without making it runny. The batter is ready when it's smooth, thick and glossy like cream.
Step 5
Weigh the total amount of batter and divide it evenly among six bowls, then add to taste gel food coloring to each bowl in the six colors of the rainbow and stir well. Weighing the portions gives six layers of equal thickness, and gel coloring gives deep shades without thinning the batter. Each bowl is ready when the color is even and vivid with no white streaks.
Step 6
Pour each color into a pan, spread it level and bake each batch at 175°C for about 15 to 18 minutes. Thin layers bake quickly, and baking them just long enough keeps the colors bright without the tops browning. A layer is done when the top is dry, springs back when pressed lightly and a skewer comes out clean.
Step 7
Let each layer rest in its pan for five minutes, then turn it out onto a rack, peel off the paper and let it cool for about an hour. Only completely cool layers are firm enough to stack without breaking or melting the frosting. The layers are ready when the center of each one feels cool to the touch.
Step 8
Beat 450 g softened unsalted butter for about two minutes, gradually add 700 g sifted powdered sugar along with a pinch salt, then add 60 g heavy cream and 8 g vanilla extract and beat for about four minutes more. A long beating makes the buttercream white, light and smooth, so it spreads into flat layers easily. The buttercream is ready when it's ivory white, fluffy and forms soft peaks when you lift the beater.
Step 9
Start with the purple layer on the bottom and stack up to the red layer, spreading a thin layer of buttercream between each one, then spread a very thin coat of buttercream over the whole cake and refrigerate for about 30 minutes. This crumb coat traps the crumbs so the final layer of frosting stays clean and smooth. The cake is ready when the crumb coat has firmed up and isn't sticky to the touch.
Step 10
Spread the remaining buttercream thickly over the sides and top of the cake, hold a bench scraper upright and turn the cake stand to smooth it, then finish with 40 g rainbow sprinkles if you like. A thick, smooth layer of frosting keeps the colors inside hidden until the moment you cut it. The cake is finished when the frosting is smooth, the edges are sharp and no cake color shows through.
Equipment
- Oven
- Round cake pan
- Stand mixer
- Mixing bowl
- Spatula
- Sieve
- Kitchen scale
- Parchment paper
- Wire cooling rack
- Refrigerator
Tips
- Use gel food coloring rather than liquid, because liquid coloring takes a lot to get deep colors and can thin the batter.
- If you only have two pans, leave the unbaked batter at room temperature; it will be fine for up to an hour.
- Slice the cake while it's still slightly chilled, using a long knife dipped in hot water, so the colored layers stay distinct without smearing the frosting.
Storage
Frosted with buttercream, the cake can sit in a cool room for about half a day. Store it in an airtight container in the fridge for up to four days, and let it sit out for about thirty minutes before serving so the buttercream softens again.
Common problems and how to fix them
- The cake layers are uneven in thickness.
- The batter wasn't divided by weight. Weigh the total batter, divide by six and weigh each bowl, then level the batter in the pan before baking.
- The colors look faded and yellowish after baking.
- The coloring wasn't strong enough or the layers baked too long. Mix the colors a little deeper than you want them to end up, and take the layers out as soon as they're done.
This recipe is based on the common ratios for this bake and is written entirely in our own words.



