Chocolate Zucchini Cake

Super moist and indulgent chocolate zucchini cake is studded with chocolate chips and topped with chocolate fudge frosting. Made with 3 cups of shredded zucchini (you can’t taste it!), this is the most decadent way to eat your greens.

I originally published this recipe in 2017 and have since added new photos, a video tutorial, and additional success tips.

cake server removing slice of chocolate zucchini cake.

Today, we have a triple dose of chocolate in the form of luxuriously rich chocolate zucchini cake. No, you can’t taste the zucchini. No, you can’t see the zucchini. Yes, it’s unbelievably delicious and I’m showing you exactly how to make it! Zucchini recipes have never been more decadent than this one. 🙂

Can you just look at how rich and moist this cake is? It tastes even better than it looks, I swear. The real secret behind it is the hidden vegetable inside. If you’re one who believes these veggies should only be in zucchini casserole, zucchini fritters, or zucchini biscuits and have nothing to do with dessert, keep an open mind. Carrot cake, anyone?!


Why You’ll Love This Chocolate Zucchini Cake

  • Just as loved as my chocolate cake
  • Super moist and rich with mega chocolate flavor
  • Easy to make
  • A delicious way to use up a bumper crop of summer zucchini
  • 3 cups of vegetables hiding inside—and you don’t even taste it
  • Covered in fudge-like chocolate buttercream

One reader, Stacie, commented:Delicious chocolate cake! No evidence of three cups of zucchini in there! So good!!! ★★★★★

One reader, Emily, commented:This was amazing! Probably the best chocolate cake we’ve ever had—so moist! And no one even guessed there was zucchini in it. ★★★★★

One reader, Kara, commented:This wasn’t just the best zucchini recipe I’ve ever tried, it was the best cake recipe as well! The zucchini here makes this moist and fudgy, almost like a brownie, but still fluffy like cake. I used cream cheese frosting and it was divine. I will be making this for birthdays in the future! ★★★★★

fork with a bite of a slice of chocolate zucchini cake.

Overview: Chocolate Zucchini Cake Ingredients

This decadent cake is made with fresh zucchini and pantry basics. Did you know that cocoa powder can dry out baked goods much more than flour? To compensate for this, we ensure there’s plenty of added moisture in the cake batter.

Let’s review a few key ingredients:

  • Unsweetened Natural Cocoa Powder: Cocoa powder takes the place of some flour. Just as in my regular chocolate cake recipe, make sure you’re using natural unsweetened cocoa powder instead of Dutch-process cocoa powder.
  • Espresso Powder: Espresso powder accentuates the chocolate flavor. While optional, I highly recommend using it. The chocolate zucchini cake won’t taste like coffee. Rather, the espresso powder helps bring out the intense chocolate flavor. We use it in chocolate zucchini bread and in this chocolate cake roll, too. You can find espresso powder in the coffee aisle at the grocery store or online.
  • Oil: Oil adds moisture. You can try replacing *some* of the oil with unsweetened applesauce. I’ve done this with chocolate cakes and muffins and the result is wonderful, but I don’t recommend replacing all of it. Despite the zucchini inside, this isn’t health food, it’s dessert. Don’t try to make it into something it’s not!
  • Eggs: 4 eggs bind everything together and add moisture. Remember that room-temperature ingredients are important.
  • Sour Cream: Just like in chocolate peanut butter cake, you can use sour cream or plain yogurt. Either add moisture.
  • Zucchini: Use a whopping 3 cups of shredded zucchini in this recipe. Testing how much we can get away with… without actually tasting it! Zucchini is pure magic in cakes—nothing but flavorless moisture. Same goes with my zucchini bread, apple zucchini bread, and zucchini muffins, too!

Optional Chocolate Chips: For mega chocolate flavor, add chocolate chips to the batter. They’re key to those melty pockets of chocolate in each slice. I use semi-sweet chocolate chips (just like in my peanut butter chocolate chip zucchini bread), but mini chocolate chips or even dark chocolate chips pair wonderfully, too.

ingredients on marbled surface including chocolate chips, cocoa powder, oil, flour, eggs, espresso powder, brown sugar, and sour cream.
shredded zucchini on cutting board

Let Me Show You How to Make It:

This chocolate zucchini cake comes together quickly and easily, just like my regular zucchini cake. Simply whisk the dry ingredients in one bowl and beat the wet ingredients together in another bowl. Combine the wet and dry ingredients, then add the chocolate chips. The cake batter will be slightly thick thanks to all of the zucchini! Divide the batter between two 9-inch cake pans; or you can make a quarter sheet cake using a 9×13-inch cake pan. See the recipe Notes section for details.

  • Need cupcakes instead? This recipe yields about 24–30 cupcakes. See recipe Notes.
chocolate batter in glass bowl and shown again in 2 round cake pans.
chocolate cakes in round cake pans on gold cooling rack.

Chocolate Frosting

We’re topping and filling this chocolate zucchini cake with smooth, silky, and creamy chocolate buttercream. You’ll use my favorite chocolate buttercream recipe, but increase the quantity as directed in the recipe card below.

How to Assemble a Layer Cake

If you’re new to assembling and layering cakes, or if you just need a refresher, see my How to Assemble a Layer Cake video tutorial. The quick video guide will walk you through how to stack and decorate it.

If you would rather top this cake with vanilla frosting, use the vanilla frosting included in my white cake recipe. Regardless of which you choose, you’ll have enough frosting to frost the entire layer cake AND a little leftover for some fun piping on top. Decorate however you’d like! I used Wilton 1M for the pictured piping:

chocolate frosting in glass bowl with blue spatula and shown again being spread on chocolate cake layer.
close-up of piped chocolate frosting with chocolate sprinkles and mini chocolate chips.
chocolate zucchini cake on marble and wood cake stand.

Deep, dark, luxuriously rich, crazy moist, and weirdly loaded with vegetables that you absolutely can’t taste. After one bite you’ll be convinced this is the best way to eat your veggies! You’ll love my zucchini oatmeal chocolate chip cookies, too.

More Chocolate Recipes

slice of chocolate zucchini cake with chocolate frosting on beige plate.
Print
clock clock iconcutlery cutlery iconflag flag iconfolder folder iconinstagram instagram iconpinterest pinterest iconfacebook facebook iconprint print iconsquares squares iconheart heart iconheart solid heart solid icon
slice of chocolate zucchini cake with chocolate frosting on beige plate.

Chocolate Zucchini Cake

4.9 from 226 reviews
  • Author: Sally McKenney
  • Prep Time: 15 minutes
  • Cook Time: 30 minutes
  • Total Time: 3 hours, 30 minutes
  • Yield: serves 10-12
  • Category: Dessert
  • Method: Baking
  • Cuisine: American
Save Recipe

Description

This super rich and moist chocolate zucchini cake is topped with the best chocolate frosting—you won’t even taste the vegetables!


Ingredients

Cake

  • 2 cups (250g) all-purpose flour (spooned & leveled)
  • 3/4 cup (62g) unsweetened natural cocoa powder
  • 2 teaspoons baking soda
  • 1/2 teaspoon baking powder
  • 1 teaspoon espresso powder (optional)
  • 1/2 teaspoon salt
  • 1 cup (240ml) canola or vegetable oil
  • 1 cup (200g) granulated sugar
  • 3/4 cup (150g) packed light or dark brown sugar
  • 4 large eggs, at room temperature
  • 1/3 cup (80g) sour cream or plain yogurt, at room temperature
  • 2 teaspoons pure vanilla extract
  • 3 cups (about 360g) shredded zucchini (lightly blotted; see recipe Note) (2 medium zucchini, about .751 lb.)
  • 1 cup (180g) semi-sweet chocolate chips (regular or mini)

Chocolate Buttercream

  • 1 and 1/4 cups (282g) unsalted butter, softened to room temperature
  • 3 and 1/2 cups (420g) confectioners’ sugar
  • 3/4 cup (62g) unsweetened cocoa powder (natural or Dutch-process)
  • 35 Tablespoons (45–75ml) heavy cream (or half-and-half or whole milk), at room temperature
  • 1/4 teaspoon salt
  • 1 teaspoon pure vanilla extract
  • optional for decoration: chocolate chips and/or chocolate sprinkles


Instructions

  1. Preheat oven to 350°F (177°C). Grease two 9-inch round cake pans, line with parchment paper rounds, then grease the parchment paper. Parchment paper helps the cakes seamlessly release from the pans. (If it’s helpful, see this parchment paper rounds for cakes video & post.)
  2. Make the cake: Whisk the flour, cocoa powder, baking soda, baking powder, espresso powder (if using), and salt together in a large bowl. In another large bowl using a handheld or stand mixer fitted with a paddle attachment, beat the oil, granulated sugar, brown sugar, eggs, sour cream, and vanilla together until combined. Add the zucchini and mix to incorporate. Add the dry ingredients to the batter and beat on medium speed until completely combined. Fold in the chocolate chips. Batter will be slightly thick.
  3. Pour batter evenly into cake pans. Bake for around 28–32 minutes or until the cakes are baked through. To test for doneness, lightly poke the top of the cake with your finger—if it bounces back instead of leaving , the cake is done. Or you can insert a toothpick into the center of the cake—if it comes out clean, it’s done.
  4. Set the cakes on a cooling rack and let cool in the pans for 1 hour. After 1 hour, remove the cakes from the pans, discard the parchment rounds, and let the cakes finish cooling directly on the rack. The cakes must be completely cool before frosting and assembling.
  5. Make the buttercream: With a handheld or stand mixer fitted with a paddle attachment, beat the butter on medium speed until creamy, about 2 minutes. Add confectioners’ sugar, cocoa powder, 3 Tablespoons of cream, salt, and vanilla. Beat on low speed for 30 seconds, then gradually increase to high speed and beat until it’s smooth and creamy. Do not over-whip. Add 1/4 cup more confectioners’ sugar or cocoa powder if frosting is too thin or 1–2 more Tablespoons of cream if frosting is too thick. (I usually add 1 more.) Taste. Add another pinch of salt if desired.
  6. Assemble and frost: First, using a large serrated knife, slice a thin layer off the tops of the cakes to create a flat surface. Discard (or crumble over ice cream!). Place 1 cake layer on your cake stand, cake turntable, or serving plate. Evenly cover the top with a heaping cup of frosting. Top with 2nd cake layer and spread the remaining frosting all over the top and sides. Pipe any leftover frosting on top. (I used Wilton 1M tip.) Decorate with chocolate sprinkles or chocolate chips if desired. Slice and serve.
  7. Cover leftover cake and store at room temperature for up to 2 days or in the refrigerator for up to 5 days.

Notes

  1. Make Ahead Instructions: Prepare cakes and frosting 1 day in advance. Keep cakes at room temperature, covered tightly. Refrigerate prepared frosting in an airtight container, then bring to room temperature when ready to use. Frosted or unfrosted cakes may be frozen up to 2 months, thaw overnight in the refrigerator and bring to room temperature, if desired, before serving.
  2. Special Tools (affiliate links): Box GraterGlass Mixing Bowls | Electric Mixer (Handheld or Stand) | 9-inch Round Cake Pan | Cake Turntable | Wilton 1M Piping Tip | Piping Bag (Reusable or Disposable) | Cake Carrier (for storage)
  3. Blot the Zucchini: Give the shredded zucchini a very light blotting with a towel. Don’t squeeze too much moisture out, just a little blot before adding to the wet ingredients. I own and love this box grater—works quickly!
  4. 9×13-inch Cake: Interested in making a sheet cake instead? This batter will fit into a 9×13-inch pan. The bake time is long—at least 45 minutes to ensure the thick cake is baked through. Same oven temperature.
  5. Non-Chocolate Zucchini Cake: Looking for zucchini cake without chocolate? Here is my regular zucchini cake topped with brown butter cream cheese frosting.
  6. Cupcakes: This recipe yields 24–30 cupcakes. Bake for 18–22 minutes or until a toothpick inserted in the center comes out *mostly* clean with no wet batter. Same oven temperature.

Instead of cake, try these as cupcakes! Directions in the recipe Notes above.

chocolate zucchini cupcake topped with chocolate fudge frosting
sally mckenney headshot purple shirt.
About the Author

Sally McKenney

Sally McKenney is a baker, food photographer, and New York Times best-selling author. Her kitchen-tested recipes and step-by-step tutorials have given millions of readers the knowledge and confidence to bake from scratch. Sally’s work has been featured on TODAY, Good Morning America, Taste of Home, People, and more.

Read More

Reader Comments and Reviews

  1. Corinne K says:
    August 12, 2023

    Everyone raved about how moist and delicious this cake was. I food processed the zucchini and removed the seeds because the last time I made this, my kids claimed they could feel strings of zucchini in it. I was a bit concerned because the recipe claims the batter is thick, but mine was runny. I didn’t need to worry. It came our perfectly. I think the food processor is the way to go. I used peanut butter frosting. Great recipe! Thank you.


  2. Ellie says:
    August 12, 2023

    This is the best recipe ever. I didn’t even need the frosting. Sooo delish

  3. Kristy says:
    August 11, 2023

    I can’t eat dairy. What do you suggest in place of the cream cheese or yogurt?
    Would another egg work?
    Thanks.

    1. Michelle @ Sally's Baking says:
      August 12, 2023

      Hi Kristy, We haven’t tested a dairy free version of this cake but let us know if you do!

  4. Ann says:
    August 10, 2023

    One of the best cakes I have ever eaten. Will definitely be making again.!

  5. Trish Poirier says:
    August 10, 2023

    I’ve made this several times over 3 years. It’s simply the best. I love the chocolate buttercream frosting.

  6. Barb says:
    August 9, 2023

    OK this recipe is probably the best chocolate cake I have ever had. Second time I made it I took it even further over the top – added 2-3 cups of frozen raspberries at the very end. Definitely no need for any type of icing!!!

  7. A.M says:
    August 9, 2023

    Can’t wait to try this! Any chance I can frost this cake one day prior to serving?

    1. Trina @ Sally's Baking says:
      August 9, 2023

      After decorating anything with buttercream or cream cheese frosting, it’s fine for 1 day at room temperature. After that, we would refrigerate it. But, use your best judgment and whatever you are comfortable with!

  8. Becky Fernette says:
    August 8, 2023

    Made this as a sheet cake with vanilla buttercream frosting – so good and moist. Received many compliments! Sally never disappoints!

  9. Tracy says:
    August 7, 2023

    I know it says it can be made one day in advance, but any chance that can stretch to two days? I’d like to make the cake on Friday night and serve it on Sunday if possible

    1. Sally @ Sally's Baking says:
      August 8, 2023

      Hi Tracy, that should be fine. Just keep the cake layers covered at room temperature, and then frost/assemble as close to serving as you can.

  10. Sally says:
    August 5, 2023

    Is there any measurements for the chocolate frosting?

    1. Michelle @ Sally's Baking says:
      August 5, 2023

      Hi Sally, we recommend using this Chocolate Buttercream.

  11. PatE says:
    August 3, 2023

    What a terrific recipe for garden zucchini usage. Not only was it delicious, real easy to make but the recipe can also be cut in half. I made it as written and baked it in a 9×13 instead of layers. I wouldn’t change anything. If you are a chocolate lover and not a veggie lover this recipe will make a veggie believer out of you. Thank You!!

  12. Mariya says:
    August 1, 2023

    Can I make this with whipped cream instead of frosting?

  13. Jackie H says:
    August 1, 2023

    Hello,
    If I wanted to use an espresso shot instead of powder, how would I adjust the ingredients so the cake doesn’t get too runny?

    1. Lexi @ Sally's Baking says:
      August 1, 2023

      Hi Jackie, we don’t recommend adding a shot of espresso because as you mention, it will add too much liquid to the batter. You can simply omit the espresso powder if you don’t have any on hand. It will still be delicious and plenty chocolatey!

  14. Daniela says:
    July 31, 2023

    Bitter and healthy tasting

  15. Deborah says:
    July 28, 2023

    Where do you usually buy espresso powder? I don’t drink coffee of any type so don’t know where do get it.

    1. Stephanie @ Sally's Baking says:
      July 28, 2023

      Hi Deborah, We can find it in just about any grocery store in the coffee/tea aisle.

  16. Afton says:
    July 23, 2023

    The cake was fantastic! Definitely a keeper.

  17. Beamer's Mom says:
    July 21, 2023

    MY FAVORITE CHOCOLATE CAKE!!!!! I use a 9×13 pan and then use a little 5×5″ for the extra. This recipe is absolutely worth trying. So good alone, I don’t even frost it. SOOOO yummy with those chocolate chips, hot out of the oven or cold. Thanks SALLY!

  18. Jackie C says:
    July 15, 2023

    Excellent! Moist and chocolatey – no need for frosting. I halved the recipe and baked in a 9” square pan. Perfection and no one would guess it has zucchini inside.

  19. Andrea Audrey says:
    July 14, 2023

    I wish I had read the comments and used coconut oil instead of canola, all I can taste is the canola oil. Pretty much tastes like a chocolate cake from a box you can get from the store. A lot of effort later and I’m not really happy 🙁

  20. LynnAmwake says:
    July 7, 2023

    Hubby said best chocolate cake he ever tasted. Everyone agreed. The grandkids have NO IDEA there are veggies in it. Even bette4 on second day when all the moisture is there. Love the icing too.

  21. Sandra Mak says:
    July 4, 2023

    Fantastic chocolate cake❤️ Thank you so much. So easy. I am astounded there isn’t a single shred of zucchini visible after baking. The cake is delicious without frosting. I use a fudge frosting recipe my Aunt Doris gave me. I peel the zucchini, cut it into chunks and pulse it 2-4 times in the blender. Quicker and easier than shredding. I am sure many of you do the same❣️

  22. Peggy says:
    June 5, 2023

    I would like to clarify with you on the ingredients. Is 2 teaspoons baking soda and 1/2 teaspoon baking powder correct? Should it be 2 teaspoons baking powder and 1/2 teaspoon baking soda? Pls advise. TQ

    1. Sally @ Sally's Baking says:
      June 5, 2023

      Hi Peggy, the recipe as written is correct.

      1. Peggy says:
        June 5, 2023

        I absolutely love the outcome of this cake. It has risen well even tho I use 2 teaspoons baking powder and 1/2 teaspoon baking soda. As I always prefer teller cakes, I used two 7 inch round cake pan and bake slightly longer. It turns out moist and soft. Love the texture and taste of it. Will definitely make again

  23. Jessica says:
    June 4, 2023

    Hi Sally,
    I wanted to know if I half the entire recipe will it be enough batter to make a 3 layer 6” cake?
    Also can I substitute the vegetable oil with refined coconut oil?

    1. Michelle @ Sally's Baking says:
      June 4, 2023

      Hi Jessica, You can cut the recipe in half and just make a single layer 8 or 9 inch cake. If you wish to change the pan size you can use the post on Cake Pan Sizes and Conversions to calculate how much batter to use. We recommend 1 cup of melted coconut oil as a substitute for the vegetable oil. Enjoy!

  24. tanya petrova says:
    May 30, 2023

    Made these today as muffins, so no frosting. I halved the recipe and got exactly 12 muffins. Used coconut oil instead of canola. Really tender crumb and excellent flavor. Not overly sweet. Would never guess there were zucchini in it, if I hadn’t put them in the batter myself. Thank you, Sally!

  25. Desire says:
    May 25, 2023

    I don’t use inflammatory causing oils can peanut oil be used or an olive oil

    1. Sally @ Sally's Baking says:
      May 25, 2023

      Extra virgin olive oil works wonderfully here.

  26. M B says:
    May 24, 2023

    Would this cake work in a bundt pan?

    1. Lexi @ Sally's Baking says:
      May 24, 2023

      Hi MB, We’re unsure of the exact bake time for a Bundt cake, but it will take well over the time needed for the cake layers. Keep a close eye on it and use a toothpick to test for doneness.

  27. Rachel says:
    May 4, 2023

    This is such a great cake! It is so rich and decadent but light and fluffy at the same time. Stayed fresh for days – it makes a pretty big cake. Loved it and will definitely be making this regularly.

  28. Ann B says:
    May 3, 2023

    Help! I have made this many times but will be making it at 7,000 feet for the first time! Can you help me adjust it?

    1. Lexi @ Sally's Baking says:
      May 3, 2023

      Hi Ann, we wish we could help, but we have no experience baking at high altitude. Some readers have found this chart helpful: https://www.kingarthurflour.com/learn/high-altitude-baking.html

  29. Steph M says:
    April 28, 2023

    Could this recipe be halved? I’d like to make cupcakes but 24-30 is WAY more than I need. Anything special I need to consider if aiming for 12-14 cupcakes?

    1. Lexi @ Sally's Baking says:
      April 28, 2023

      Hi Steph, you can certainly halve this recipe by halving all the ingredients. Enjoy!

  30. Kitty says:
    April 26, 2023

    i made this for my husband’s birthday and he calls it’s his favourite chocolate cake now. the cake kept really well in room temperature even in our tropical heat, and it’s even more yummy with Sally’s buttercream (i used vanilla). it also stayed yummy after chilling in the fridge overnight and i can’t stop eating the leftovers!