Rainbow cake

Rainbow cake

  • 1
  • 2
  • 3
  • 4
  • 5
(71 ratings)

Prep: 2 hrs Cook: 1 hr

For the keen cook

Cuts into 18 slices
A stunning celebration cake of six or seven colourful layers and cream cheese frosting - an impressive showstopper.

Nutrition and extra info

  • Freeze un-iced sponges only

Nutrition: per slice

  • kcal601
  • fat29g
  • saturates18g
  • carbs73g
  • sugars47g
  • fibre2g
  • protein11g
  • salt0.6g
Save to My Good Food
Please sign in or register to save recipes.


You'll need 3 x these ingredients for six sponges

  • 125g butter, softened, plus a little extra for greasing



    Butter is made when lactic-acid producing bacteria are added to cream and churned to make an…

  • 225g plain flour
  • 150g golden caster sugar
  • 3 medium egg (very important to use the correct size)
  • 1 tsp baking powder

    Baking powder

    bay-king pow-dah

    Baking powder is a raising agent that is commonly used in cake-making. It is made from an alkali…

  • pinch of salt
  • 1 tsp vanilla extract
  • edible food colouring - red, orange, yellow, green, blue and purple, plus optional pink (see below)

For the icing

  • 1 tsp vanilla extract
  • 3 x 250g tubs cream cheese or mascarpone
  • 350g icing sugar


  1. Heat oven to 180C/160C fan/gas 4. Grease 2 x 20cm round sandwich tins and line the bases with baking parchment. Tip all the sponge ingredients, apart from the food colouring, into a mixing bowl, then beat with an electric whisk until smooth.

  2. Working quickly, weigh the mixture into another bowl to work out the total weight, then weigh exactly half the mixture back into the mixing bowl. Pick 2 of your colours and stir a little into each mix. Keep going until you are happy with the colour – the colour of the batter now will be very similar to the finished cake, so be brave! Scrape the different batters into the tins, trying to spread and smooth as much as possible – but try not to waste a drop of the batter – a rubber spatula will help you. Bake on the same oven shelf for 12 mins until a skewer poked into the middle comes out clean.

  3. Gently turn the cakes out onto a wire rack to cool. Wash the tins and bowls thoroughly, and start again from step 1 – this time using another 2 colours. Unless you’re making the optional pink layer, repeat one more time to get 6 sponges, all of different colours. Leave them all to cool.

  4. To make the icing, very briefly beat the vanilla and cream cheese or mascarpone with an electric whisk until smooth. Sift in the icing sugar and gently fold in with a spatula. Be careful – the more you work it, the runnier it will get, increasing the chance of splitting.

  5. Smear a little icing on your cake stand or plate – just a splodge to stick the first sponge. Start with the red, then spread with some icing right to the very edge. Repeat, sandwiching on top the orange, yellow, green, blue and finally purple sponges. Spread the remaining icing thickly all over the sides and top of the cake. For more tips and expert advice on how to create the perfect rainbow cake, check out our tips, below.

Ads by Google

Comments, questions and tips

Sign in or create your My Good Food account to join the discussion.

Comments (136)

owlsandantlers's picture

Tastes okay but the colours got completely messed up. Will find gels next time as I used bottles.. purple turned grey, green turned yellow and red turned brown. Looks like a cake from a faded photograph!

delmorse's picture

Why does the recipe description state that it's a cake with buttercream when the icing is made up with cream cheese?

Mimilittlebaker's picture

Great recipe! I enjoy baking but I admit I am not the best. I was little put off by all the negative comments but I had a go. Looked and tasted great. I have three tips.
+make the icing first and put it in the fridge.
+to add flavour I added lemon zest which was really successful.
+small slices!!!it is very filling but delicious. SMALL SLICES

calderem's picture

Firstly - what colours did I use? I used Wilton colour pastes - about 1/4 of a jar for each layer - which made for a really vibrant colour without any bitter taste.

The cake mixture was great I thought. It is quite dense - nothing like a Victoria sponge - but if you smooth it well when you put the batter in the tin, then you will get a fairly flat cooked cake. It does not dome in the middle as it rises in the oven. The denseness of the cake also means that it lasts well and does not go stale quickly.

The place where I really came a cropper was the icing and if I did it again then I would use a butter cream. I would say that you have to put the mixed icing in the fridge for at least 3 hours before you have the remotest change of getting a 'thick' layer over the side of the cake. Also with the cream cheese icing you do need then to keep the cake cool - which as it is s big necessitated removing a shelf from my fridge to fit it in!

On the whole a great success though.

flowerycook's picture

After reading the comments I sought out Sugar Flair gels at a local craft shop as I could only find Dr Oetker colours at the supermarkets. Other than that, and using normal buttercream icing instead of the mascarpone one I followed the recipe to the letter. It took a good few hours but was not in anyway complicated, the finished cake looked and tasted amazing.

Michellersmith's picture

This was a fairly straight forward recipe although I did add more sugar than suggested and had to cook for a lot longer ( but I think this was due to not have a fan assisted oven) I used the colour pastes that were suggested on the tips page they worked a dream - I got vibrant colours with altering the taste! Thanks for the recipe and the tips!

louiseholistic's picture

I was disappointed with this, especially after the amount of time spent making it. The cakes took much longer than 15 minutes to bake, the whole thing was very heavy and dense and the colourings (I used Dr Oetker) gave it a very strange taste. Although the colours themselves were muted, the cake looked really impressive when we cut into it, it's such a shame the taste doesn't deliver.

quilty's picture

Just thought I'd post to say that this recipe is excellent! After reading many of the negative comments I wasn't sure whether or not to go ahead and make it but trusted that the Good Food team would not have a recipe that didn't work.
It does work! The only difference that I made was that I ran out of plain flour after that first batch of cakes and so substituted Self Raising for the next ones. The cakes came out just as well. The colour was good, they were well risen but flat on top and needed no trimming. Layered up they looked amazing and tasted just as good as they looked.
I made this for my daughters' 21st Birthday and she thought it was brilliant.
I see that some people are saying to make a Victoria sponge instead but I don't think this would work as well. Victoria sponge has a totally different texture to these. These cakes are more squidgy and dense - but still good!
Please try it - they taste super!
One change I made to the cheese frosting is to make a normal buttercream first with butter and icing sugar and only then add the cream cheese. This results in a more stable icing that does NOT go runny.

ShurikenNinja's picture

This looks delicous :)

Denisemasr's picture

Do not try this recipe!! I baked it and it was horrible! The cake was really hard!

I tried using an vanilla sponge recipe and adding colouring to it and it's much better..

andrea.maddin's picture

If I could give this recipe a 0 then I would. I made this twice as i thought I must have gone wrong but it tastes horrible. Very dense and doughy. I like to think I can bake and have made many cakes in my life but this recipe just didn't work. I would recommend that you adapt a victoria sponge recipe and go from there.

RainbowCake7533's picture

You must have done something wrong, because I did it and it tasted great!

veato's picture

"try Dr Oetker gel food colours in Bright Red, Neon Orange, Sunshine Yellow, Lime Green, Sky Blue, Ultra Violet and Hot Pink" -- Personally I wouldn't. I used 2 Dr Oetker tubes per layer of a similar rainbow cake and the colour was not very vibrant at all. Try Wilton or Americolor.

bakinggirl999's picture

looks great but tastes horrid

Kerry Cooks's picture

So rubbish that everyone is still having issues with this cake! If you want a more reliable one, try my recipe - check out the comments for all the positive reviews!

sabrinaduck's picture

After my earlier mishap with rainbow cake using the BBC Good Food recipe above, I decided to try your recipe. The result was perfect. Thank you Kerry.

kerielaine1's picture

I made this cake for my and my girlfriend's 6 month anniversary. I followed the recipe exactly, aside from the pink layer. I wanted a traditional rainbow. ;) I used Dr. O's food gels in red, yellow and green, mixing my own secondary colours. Even though each layer appeared a bit light, once put together they complimented each other nicely. If I wasn't a poor student I would have bought 6 individual gels for brighter colours but I was trying to keep the cost under 10 quid. The cream cheese icing was perfect. I stuck it in the fridge to chill and set up a bit because it was initially pretty runny. First time ever making sponge. First time ever making my own frosting and first 6 layer cake! It turned out perfect! She loved it, I loved it, the friends we shared with loved it. Thank you!

kerielaine1's picture

In terms of what I used, I used red, blue and yellow food gels. Mixing my own secondary colours. I used the cream cheese icing as the recipe called for, even using Lidl brand soft cheese as I'm a poor uni student. Wish I could attach a photo. The recipe was easy, first time ever making sponge. So happy.

kerielaine1's picture

Made this cake for a 6 month anniversary for my girlfriend and I. Followed it exactly aside from not doing a pink layer. She loved it and everyone who tried it thought it was beautiful AND delicious.

stravers's picture

My daughter wanted this cake for her 4th Birthday, we decorate with strawberries it looks fantastic but it is quite filling and heavy.


Questions (20)

Unsure about the cooking time or want to swap an ingredient? Ask us your questions and we’ll try and help you as soon as possible. Or if you want to offer a solution to another user’s question, feel free to get involved…

Be the first to ask a question about this recipe…

Tips (2)

Got your own twist on this recipe? Or do you have suggestions for possible swaps and additions? We’d love to hear your ideas.

Be the first to suggest a tip for this recipe…

Skills & know how

As well as helping you decide what to cook we can also help you to cook it. From tips on cookery techniques to facts and information about health and nutrition, we’ve a wealth of foodie know how for you to explore.

About BBC Good Food

We’re all about good recipes, and about quality home cooking that everyone can enjoy. Whether you’re looking for some healthy inspiration or learning how to cook a decadent dessert, we’ve trustworthy guidance for all your foodie needs.

Our recipes

All our recipes are tested thoroughly by us to make sure they’re suitable for your kitchen at home. We know many of you are concerned about healthy eating, so we send them to a qualified nutritionist for thorough analysis too.

Tell us what you think…

Love the new look or think we’ve missed the mark? We want to hear your thoughts – good and bad – to make sure we make the new website as useful as possible.


Subscribe to BBC Good Food magazine and get triple-tested recipes delivered to your door, every month.


Discover the dates and details of all the BBC Good Food Shows.


See your favourite chefs on Sky Channel 247, Virgin TV 260 and find their recipes at

Follow us

Join the BBC Good Food community by following us on Facebook, Twitter, Pinterest, Instagram and Google Plus.