Skip to Content

Galaxy Cake

This Galaxy Cake is made with tender layers of white cake, and vanilla frosting. We use natural food colorings to color the frosting to make vibrant colors that make this cake look like it's out of this world. 

Are you planning a space-themed birthday party and need a birthday cake? This delicious cake is the best cake to make for special occasions just like this. This beautifully decorated cake will be the star of the party I can guarantee you! 

While this cake makes seem a little complicated to make, don't let the ingredients list and instructions intimidate you. It really is simple to make and your family will love it. Even beginners can make this delicious cake. 

A cake decorated to look like space.

Why You’ll Love This Galaxy Cake Recipe 

  • Tender vanilla cake layers topped with creamy and beautifully colored frosting make this cake perfect for the dessert table. 
  • You don't have to worry about artificial food colors with this simple recipe. 
  • It's a great dairy-free and gluten-free birthday cake idea. 

Ingredients Notes

Get more info on these ingredients in the recipe card.

  • granulated sugar
  • vegetable oil
  • large eggs
  • vanilla extract
  • dairy-free sour cream- Tofutti has almost always been our go to, but recently we tried this out and it worked well too
  • gluten- free flour - King Arthur's measure for measure, Bob's Red Mill, or GFJules have all been ones we enjoyed using.
  • baking powder
  • salt
  • dairy free milk- we used almond milk, but you can use whatever you prefer.
  • dairy free butter- Earth's Balance is our go to
  • confectioners’ sugar
  • dairy free heavy whipping cream
  • beetroot powder
  • butterfly pea powder
  • matcha powder
  • baked cocoa
  • pea powder
  • White food coloring
Looking down on a galaxy cake on a cake plate.

Helpful Tools 

Measuring Cups and Spoons

Mixing bowls 

Electric mixer  - hand mixer or stand mixer 

Offset spatula 

Round cake pans

Cake plate or cake board

Small paint brush

How To Make This Galaxy Cake

  1. Preheat the oven to 350 degrees. 
  2. In a large bowl mix together the eggs, sugar, vanilla, and oil until fully incorporated. 
  3. Stir in the sour cream and milk and combine. 
  4. In another medium bowl mix the flour, baking powder, and salt. 
  5. Gradually mix the dry ingredients Into the wet ingredients until smooth.
  6. Spray two 6” cake pans with cooking spray and pour half the batter into each one. 
  7. Place the pans on a baking sheet and bake at 350°f for 20 minutes. Test the center of the cakes with a toothpick to be sure they’re fully cooked.
  8. Cool completely before removing the cakes from the pan. 
  9. While the cakes are cooling make the frosting by adding the butter, 3 cups of confectioners sugar, and half of the cream and vanilla. 
  10. Mix until creamy, gradually adding and alternating the remaining sugar, cream, and vanilla.
  11. Once the frosting is mixed, increase the speed to high and whip the frosting for 5 minutes.
  12. Divide the frosting in half.  And, then set aside 1 half. 
  13. Divide the other half into thirds.
  14. To mix the pink color, add beetroot powder 1 teaspoon at a time until the desired colored.
  15. To mix the blue color, add butterfly pea powder 1 teaspoon at a time until the desired colored.
  16. To mix the black color, add beetroot, butterfly peas, matcha powders, and cocoa, 1 teaspoon at a time until the desired color.
  17. Divide the remaining ½ of the white buttercream by removing ⅓ and setting aside for any mistakes. 
  18. Once cakes are fully cooled, using a cake or bread knife slice off the risen center of the cakes to make them flat and stackable.
  19. Place the bottom layer on a cake plate or flat surface. Add a dollop of white frosting and evenly spread leaving a ½” thickness.
  20. Flip the other cake upside down and on top of the frosted cake. 
  21. Completely frost the two layers of cake with a thin layer of white buttercream frosting.
  22. Now apply small dollops of the pink and blue frosting across the entire cake. Then fill in the remaining space with the black frosting. 
  23. Using an offset spatula or knife, spread the frosting around to create a black space like a void with splashes of pink and blue and inevitably purple nebula-like clouds. 
  24. Once the frosting reaches the desired mixture. Dip a small watercolor paintbrush in the white food color and flick it on the cake. This will round out the design with stars and hopefully give the illusion of infinite depth.
A collage of images showing how to make a galaxy cake.
A collage of images showing how to maek and decorate a galaxy cake.
A collage of images showing the last few steps of decorating a galaxy or space cake.

Storage

Store in an airtight container in the refrigerator for up to one week. Serve chilled or leave at room temperature for about 10 minutes before serving. Enjoy!

Recipe Variations

  • Food coloring:  If you don't want to use natural food coloring you can use gel food colorings to make the colors instead. 
  • Flavors: Feel free to experiment with different cake flavors. You can try chocolate, strawberry, lemon, or whatever you like!
  • Galaxy Mirror Glaze Cakes: To give the cake a real "galaxy" feel, add glitter glaze on the top of the cake, and drizzle some down the sides of the cake if you prefer. 
A caked decorated to look like the galaxy.

Tips & Tricks

  • We don't recommend using different colors for this because these colors really give this cake the perfect deep sky look. 
  • You could also pick up some edible planets or food-safe astronauts for the outside of the cake if you want a little extra flare. 
  • For easy and clean removal of the cake from the pans, line your baking pans with parchment paper and then spray the parchment paper with nonstick cooking spray. 
Looking down on a decorated space cake.

FAQ

What are the colors of the Galaxy Cake?

You will need pink, blue, and black frosting colors to make this cake. 

Does this cake have a mirror glaze? 

No, we didn't use a mirror glaze for this cake. However, you can add one if you prefer.

​How do I know when a cake is finished baking? 

You can tell that a cake is finished baking when a toothpick inserted into the center comes out clean. 

A caked decorated to look like the galaxy.

More Cake Recipes

A bite of galaxy cake sitting next to the rest of the piece fo cake.
A space cake or galaxy cake.

Galaxy Cake

This fun, space themed cake is the perfect special occasion or birthday cake to make for any galaxy lover in your life!
No ratings yet
Print Pin Rate
Course: Dessert
Cuisine: American
Prep Time: 1 hour
Cook Time: 20 minutes
Total Time: 1 hour 20 minutes
Servings: 6 servings
Author: Eating Gluten and Dairy Free

Ingredients

Cake:

  • 1 cup granulated sugar
  • ¼ cup vegetable oil
  • 2 large eggs
  • 2 teaspoons vanilla extract
  • ¼ cup df sour cream
  • 1 ¼ cups gf flour Bob’s red mill, or King arthurs baking blend all work
  • 1 ½ teaspoon baking powder
  • ½ teaspoon salt
  • cup df milk we like almond milk but you can use any alternative

Frosting:

  • 1 cup df butter softened to room temperature- we use Earth’s Balance or Country Crock’s Plant Based Sticks
  • 4 cups confectioners’ sugar
  • 2 tablespoons df heavy whipping cream we use Silk
  • 2 teaspoons vanilla extract - always make sure your is safe

Galaxy

    Pink

    • 2 teaspoons beetroot powder or more if you desire

    Blue

    • 2 teaspoons butterfly pea powder or more if you desire

    Black

    • 4 teaspoons matcha powder
    • 4 teaspoons baked cocoa
    • 2 teaspoons pea powder

    “Stars”

    • White food dye

    Instructions

    • Preheat the oven to 350 degrees.
    • In a large bowl mix together the eggs, sugar, vanilla, and oil until fully incorporated.
    • Stir in the sour cream and milk and combine.
    • In another medium bowl mix the flour, baking powder, and salt.
    • Gradually mix the dry ingredients Into the wet ingredients until smooth.
    • Spray two 6” cake pans with cooking spray and pour half the batter into each one.
    • Place the pans on a baking sheet and bake at 350°f for 20 minutes. Test the center of the cakes with a toothpick to be sure they’re fully cooked.
    • Cool completely before removing the cakes from the pan.
    • While the cakes are cooling make the frosting by adding the butter, 3 cups of confectioners sugar, and half of the cream and vanilla.
    • Mix until creamy, gradually adding and alternating the remaining sugar, cream, and vanilla.
    • Once the frosting is mixed, increase the speed to high and whip the frosting for 5 minutes.
    • Divide the frosting in half.  And, then set aside 1 half.
    • Divide the other half into thirds.
    • To mix the pink color, add beetroot powder 1 teaspoon at a time until the desired colored.
    • To mix the blue color, add butterfly pea powder 1 teaspoon at a time until the desired colored.
    • To mix the black color, add beetroot, butterfly peas, matcha powders, and cocoa, 1 teaspoon at a time until the desired color.
    • Divide the remaining ½ of the white buttercream by removing ⅓ and setting aside for any mistakes.
    • Once cakes are fully cooled, using a cake or bread knife slice off the risen center of the cakes to make them flat and stackable.
    • Place the bottom layer on a cake plate or flat surface. Add a dollop of white frosting and evenly spread leaving a ½” thickness.
    • Flip the other cake upside down and on top of the frosted cake.
    • Completely frost the two layers of cake with a thin layer of white buttercream frosting.
    • Now apply small dollops of the pink and blue frosting across the entire cake. Then fill in the remaining space with the black frosting.
    • Using an offset spatula or knife, spread the frosting around to create a black space like a void with splashes of pink and blue and inevitably purple nebula-like clouds.
    • Once the frosting reaches the desired mixture. Dip a small watercolor paintbrush in the white food color and flick it on the cake. This will round out the design with stars and hopefully give the illusion of infinite depth.

    Nutritional Disclaimer

    These Nutritional Facts are ESTIMATED. Your actual nutritional info with this recipe may vary depending on the brands you choose. “Eating Gluten and Dairy Free” is not a registered dietician or nutritionist. The provided nutritional info above is based on a generic calculator, if you want more accurate info, use your nutritional calculator of choice where you can choose brands and get more info that way.

    Share for others and save for later!

    Recipe Rating