With the 4th of July holiday weekend approaching, I find myself wanting to share the most colorful and festive recipes with you.  I began the week with the most delicious Monster Cookie Ice Cream Sandwiches that were bursting with colorful M&M’s and now I have perhaps the most colorful creation I have yet to make:  M&M Rainbow Cake!

How to make a Rainbow Cake {satisfymysweettooth.com}

Every person who saw this cake immediately asked, “how did you make that?”  So I have a full photo tutorial of how to make a rainbow cake for you.  I promise it is super simple, yet the results are so bright and vibrant.  I love that you can customize this technique to coordinate with whatever event you are making a cake for.  I will tell you how to customize the cake a little later.

How to make a Rainbow Cake {satisfymysweettooth.com}

For now, let’s run through the steps of how to make a rainbow cake so that you can see how truly easy it is.

We begin with a classic butter cake recipe.  I used my favorite butter cake recipe from The America’s Test Kitchen Family Baking Book, but here’s where you could make it even simpler and use any white or yellow box cake mix if you want to.  Once the cake batter is well combined, you simply divide the batter evenly into as many medium-sized bowls as colors of cake you want.  I divided the batter into six bowls because I wanted all of the colors of the rainbow:  red, orange, yellow, green, blue and purple.  (If, for example, you wanted to make a red, white and blue cake for the 4th of July, you would divide the batter into only three bowls.)  When I say divide the batter “evenly”, I mean roughly evenly.  I didn’t measure or weigh my bowls to be exact when dividing the batter I just eyeballed it.

How to make a Rainbow Cake {satisfymysweettooth.com}

Next you will mix a different color food coloring into each bowl.  I like the gel food coloring because the colors are so potent and vibrant.

How to make a Rainbow Cake {satisfymysweettooth.com}

How to make a Rainbow Cake {satisfymysweettooth.com}Now it’s time to put the colored batter into your pans.  For this cake, I used two 9-inch round cake pans.  Pour half of your first color (red in my case) into each pan.

How to make a Rainbow Cake {satisfymysweettooth.com}

Next, take your second color (orange for me) and pour half of that color batter slowly into the center of the first color in each of the two pans.  The first color will slowly spread into a wider circle as you pour your second color in the middle of it.

How to make a Rainbow Cake {satisfymysweettooth.com}

Proceed with the remaining colors until it looks like this:


That’s it as far as the color layering goes!  I told you it was easy!

Now off to the oven with the cakes to bake.

How to make a Rainbow Cake {satisfymysweettooth.com}

How to make a Rainbow Cake {satisfymysweettooth.com}

Once cooled, you frost and decorate the cake any way you like.  For a tutorial about how to frost a layer cake CLICK HERE.  I used Mega and regular-sized M&M’s for my decorative pattern.

How to make a Rainbow Cake {satisfymysweettooth.com}

How to make a Rainbow Cake {satisfymysweettooth.com}

How to make Rainbow Cake

Prep Time: 1 hour

Cook Time: 24 minutes

Total Time: 1 hour, 24 minutes

Yield: 1 2-layer 9-inch cake

How to make a rainbow cake: A step-by-step tutorial with photos that will show you how truly easy this colorful cake is to make


    For the cake
  • 1/2 cup half and half
  • 4 large eggs
  • 2 tsp vanilla
  • 1 3/4 cups cake flour
  • 1 1/2 cups sugar
  • 2 tsp baking powder
  • 3/4 tsp salt
  • 1 cup (16 Tbsp) unsalted butter, room temperature and cut into Tbsp-sized pieces
  • food coloring
  • For the buttercream frosting
  • 1 cup (16 Tbsp) unsalted butter, room temperature
  • 2 cups powdered sugar
  • 2-4 Tbsp milk
  • 1 tsp vanilla


    For the cake
  1. Preheat oven to 350 degrees.
  2. Grease and flour 2 8 or 9-inch round cake pans. Line the bottom of the pans with parchment paper.
  3. In a small bowl, or liquid measuring cup, combine the half and half, eggs and vanilla, set aside.
  4. In a large bowl, combine the cake flour, sugar, baking soda and salt. Mix to combine.
  5. Drop the butter into the flour mixture 1 piece at a time and mix using an electric mixer until the mixture resembles a coarse crumb.
  6. With the mixer running, slowly pour in the egg mixture and mix until combined, about 1-2 minutes. It's fine if the batter has a few clumps.
  7. Pour the batter evenly into six small bowls.
  8. Add red, orange, yellow, green, blue and purple food coloring to one of the bowls. Mix to combine.
  9. Pour half of the red batter into the center of each pan.
  10. Slowly pour half of the orange batter into the center of the red batter in each pan.
  11. Slowly pour half of the yellow batter into the center of the orange batter in each pan.
  12. Slowly pour half of the green batter into the center of the yellow batter in each pan.
  13. Slowly pour half of the blue batter into the center of the green batter in each pan.
  14. Slowly pour half of the purple batter into the center of the blue batter in each pan.
  15. Bake the cakes for 20-24 minutes or until a toothpick inserted into the centers of the cakes comes out with only a few crumbs on it.
  16. Cool cakes for 10 minutes. Run a knife along the edges of the pans to release the sides of the cakes.
  17. Invert cakes on to cooling racks to remove from pans. Peel parchment paper away from bottoms of cakes and cool the cakes completely.
  18. For the buttercream frosting
  19. In a large bowl, use an electric mixer to combine the butter, powdered sugar and vanilla. Add milk 1 Tbsp at a time until the frosting is a spreadable consistency.
  20. Frost cake and decorate.
  21. Cake recipe adapted from The America's Test Kitchen Family Baking Book

Have a wonderful 4th of July weekend!

How to make a Rainbow Cake {satisfymysweettooth.com}


Print Friendly, PDF & Email
Did you like this? Share it:

You may also like:

Soft and Chewy Chocolate Sandwich Cookie Recipe
Oreo-Stuffed Chocolate Chip Cookies, The Picky Palate Cookbook Review and Giveaway!
Honey Roasted Peanut Marshmallow Bars

One Comment ( Reply )

  1. emily (a nutritionist eats)
    Jul 03, 2014 @ 6:51 pm

    That was my first thought, too, how did she do that?!! It’s SO bright and beautiful! I would have never guessed the method either, I’m surprised it isn’t more complicated.


 Leave a Reply