Go Back
+ servings
sliced rainbow cake
Print Recipe
5 from 16 votes

Rainbow Cake Recipe

Semi-Homemade Rainbow Cake is sturdy enough to stack 6 layers and the perfect vibrant rainbow cake for a fun party!
Prep Time2 hours
Cook Time30 minutes
Total Time2 hours 30 minutes
Course: Dessert
Cuisine: American
Servings: 16 servings
Calories: 202kcal
Author: Dorothy Kern
Cost: $8


  • 2 15.25 ounce packages white cake mix
  • 1 cup (124g) all-purpose flour
  • 10 large egg whites
  • 1 ½ cups (345ml) milk (full fat is best but any can be used)
  • 1 cup (245g) sour cream room temperature
  • 1 cup (237ml) vegetable oil
  • Food Coloring red, orange, yellow, green, blue, purple
  • 2 recipes Vanilla Buttercream Frosting


  • Preheat oven to 350°F. Prepare six 8-inch round cake pans: grease and flour them (or spray with nonstick baking spray with flour) and line the bottom with parchment paper. *See note for how to do this in 2 batches if you don’t have 6 pans*
  • Add cake mix, flour, egg whites, milk, sour cream, and oil to a large bowl. Mix on medium speed with a hand mixer until smooth.
  • Divide cake batter evenly into 6 bowls. (If you have a kitchen scale, you can make sure they are even by weighing the batter in each bowl as you divide it.)
  • Color each bowl a different color (one color per bowl). Stir to distribute color throughout, being sure to scrape the bottom of the bowl.
  • Pour batter in each pan (one per color).
  • Bake cake 15-20 minutes, or until a toothpick comes out clean. Cool completely before removing from pans.
  • Remove the cakes from the pans and remove parchment paper. If needed, level the cakes with a serrated knife.
  • Place purple cake layer on cake plate. Top with frosting, then add the blue layer, then green, then yellow, orange and red, making sure to frost in between each.
  • Frost the outside of the cake with a thin crumb coat of frosting. Chill cake until frosting is set to the touch then do a second layer of frosting. Decorate with sprinkles as desired.
  • Store cake covered in refrigerator for up to 3 days.
  • Make ahead: you can make the cake layers and frosting and freeze them separately for up to one month. Be sure to wrap layers well in plastic wrap and freeze frosting in an airtight container.



  • It’s important to bake these in six of the SAME pans (not different brands). Different cake pans might be slightly different and it won’t stack as well.
  • If you are buying pans, buy 3. Then make the recipe in 2 batches as follows: Mix 1 cake mix with ½ cup flour, 5 egg whites, ¾ cup milk, ½ cup sour cream, ½ cup vegetable oil. Color with 3 different colors and bake as directed. Once cool, remove from pans and repeat with remaining colors.
  • This cake is tall so it’s important your layers are flat. If they dome in the oven be sure and level them. I recommend using bake even strips to help the cakes from doming.
  • You can use canned frosting if you want, but you’ll need about 4-5 cans.
  • This would also be fantastic with Marshmallow Buttercream or Cream Cheese Frosting.
  • For the most vibrant colors, use GEL food coloring. I recommend Americolor or Wilton.


Serving: 1serving | Calories: 202kcal | Carbohydrates: 8g | Protein: 4g | Fat: 17g | Saturated Fat: 4g | Polyunsaturated Fat: 8g | Monounsaturated Fat: 4g | Trans Fat: 1g | Cholesterol: 11mg | Sodium: 46mg | Potassium: 91mg | Fiber: 1g | Sugar: 2g | Vitamin A: 127IU | Vitamin C: 1mg | Calcium: 45mg | Iron: 1mg