Desserts
This Hershey's Black Magic Cake recipe delivers the ultimate fudgy, swirled chocolate experience—just like the classic dessert you know and love. The secret lies in layers of rich cocoa cake and velvety chocolate frosting, all tied together with Hershey’s signature chocolate magic.
I’ve perfected this version after years of baking, ensuring every slice delivers that signature moist texture and deep chocolate flavor.
The beauty of this recipe is its simplicity—no fancy techniques required, just precise measurements and patience. You’ll use Hershey’s cocoa powder and chocolate syrup to create that signature swirl effect, while a simple buttercream frosting ties it all together.
The cake bakes up with a tender crumb and fudgy layers, making it impossible to resist cutting into it too soon.
What makes this cake truly special is the secret swirl technique—folding melted chocolate into the batter before baking creates those iconic ribbons of dark chocolate throughout each slice.
The result? A dessert that’s rich, decadent, and perfect for celebrations or satisfying chocolate cravings. Once you try this version, you’ll never go back to store-bought again.
Ready to bake? This recipe delivers restaurant-quality results with minimal effort, and the best part is that it’s foolproof—even for beginners. Let’s get started on creating your own Black Magic masterpiece.
Ingredients for hershey's black magic cake
Pantry staples meet chocolate magic—just 13 ingredients for restaurant-quality cake layers.
| Ingredient | Amount | Notes |
|---|---|---|
| All-Purpose Flour 🌾 | 2 ½ cups | Sifted for light texture |
| Hershey's Cocoa Powder 🍫 | ¾ cup | Natural or Dutch-processed |
| Granulated Sugar 🍚 | 2 cups | White or light brown |
| Unsalted Butter 🧈 | 1 ½ cups | Room temperature, full-fat |
| Large Eggs 🥚 | 3 whole | Room temperature, separated |
| Hershey's Chocolate Syrup 🍯 | 1 cup | Original flavor, not syrup substitute |
| Baking Powder 🧂 | 1 ½ tsp | Aluminum-free preferred |
| Salt 🧂 | ½ tsp | Fine sea salt |
| Vanilla Extract 🌿 | 2 tsp | Pure alcohol-free preferred |
| Milk 🥛 | 1 cup | Whole milk for richness |
| Hershey's Semi-Sweet Chocolate Bars 🍫 | 12 oz | Melted for swirl effect |
| Powdered Sugar 🍚 | 3 cups | For buttercream frosting |
| Heavy Whipping Cream 🥛 | 1 cup | Cold for stiff peaks |
The cocoa powder and chocolate syrup are non-negotiable for that signature Hershey's flavor. Hershey's brand delivers the authentic taste—don't substitute with generic cocoa. For the chocolate bars, Hershey's semi-sweet is perfect, but if you're in a pinch, Ghirardelli squares work too. The buttercream needs powdered sugar, but confectioners' sugar from Domino or Culinary Art brands gives the best texture. Pro tip: toast your cocoa powder in a dry pan for 2 minutes before mixing to deepen the chocolate flavor—game changer for that professional touch.
No Hershey's syrup? Melted chocolate bars plus 1 tbsp corn syrup mimics the texture. Running short on eggs? Replace 1 egg with 1 tbsp ground flaxseed plus 3 tbsp water, but the cake won't be as tender. For the buttercream, Cool Whip in a pinch gives volume but lacks richness. Want extra fudgy layers? Add 1/4 cup sour cream to the batter. The secret swirl technique requires patience—melt the chocolate bars slowly over a double boiler, then let it cool slightly before folding into the batter. Too hot and it'll cook the eggs in the batter.
This cake keeps beautifully for 3 days at room temperature covered with plastic wrap, but trust me, it won't last that long. For longer storage, slice and freeze portions for up to 3 months—thaw at room temperature before serving. The frosting can be made 2 days ahead and stored in the fridge. Rewhip with a hand mixer before frosting. For serving, dust with powdered sugar or chocolate shavings right before cutting—those swirls look even more dramatic fresh out of the oven.
Why You'll Love This Recipe
- No-Fuss Fudgy Layers: Honestly, this cake is the only one where you can prep the batter while the oven preheats—no waiting, no rushing. Just mix the dry ingredients together while the butter and sugar come to room temp, then let the mixer do the heavy lifting. The swirl technique? Takes two minutes with a butter knife.
- Chocolate Overload (In the Best Way): Between the ¾ cup of Hershey’s cocoa powder in the batter, the 12 oz of melted semi-sweet chocolate bars for the swirl, and that cup of chocolate syrup, this cake is basically a hug in dessert form. The first bite hits you with that deep, velvety cocoa flavor, and the layers? So moist they’ll make you forget cake is supposed to be dry.
- Crowd-Pleaser for Any Occasion: I baked this for my sister’s baby shower (because who doesn’t love chocolate?) and again for my coworker’s birthday—same reaction both times: “Is this homemade?” Spoiler: Yes, but it looks like it came from a bakery. The fudgy texture and rich frosting make it perfect for celebrations, but honestly? It’s my go-to for a midnight snack too.
- Leftovers That Won’t Go to Waste: This cake will disappear within 24 hours, but if you’re lucky enough to have leftovers, you’ve got options. Slice it up and freeze portions for up to 3 months—thawed, it’s still just as good. Or, if you’re feeling fancy, crumble the layers into a chocolate mousse or ice cream sundae. Trust me, no one will judge you for repurposing it.
Step-by-step instructions for Hershey's black magic cake
Here's the method that delivers fudgy layers and that legendary chocolate swirl—every slice is pure magic.
Prepare the Cake Batter with Precision
Preheat your oven to 350°F and grease two 9-inch round cake pans with unsalted butter, then line the bottoms with parchment paper. In a large mixing bowl, combine the 2½ cups all-purpose flour, ¾ cup Hershey's cocoa powder, 1½ tsp baking powder, and ½ tsp salt. Sift this dry mixture together twice to eliminate any lumps—this ensures a light, airy texture.
In a separate bowl, cream the 1½ cups unsalted butter and 2 cups granulated sugar on medium speed until light and fluffy, about 3-4 minutes. This step is critical—you're incorporating air that will make those layers rise beautifully. Add the 3 large eggs, one at a time, mixing well after each addition. Stir in the 2 tsp vanilla extract and 1 cup milk until just combined.
Gradually add the dry ingredients to the wet mixture, mixing on low speed until just incorporated. Avoid overmixing—you should still see small flour streaks. Pour the batter evenly between the prepared pans and smooth the tops. Here's the secret: before baking, swirl the batter with a knife in a circular motion to create those iconic marbled layers.
Bake and Create the Signature Swirl
Bake the cakes for 25-30 minutes, or until a toothpick inserted into the center comes out clean. The edges should be set, but the centers should still have a slight give—this ensures maximum fudginess. While the cakes are baking, melt the 12 oz Hershey's semi-sweet chocolate bars and 1 cup Hershey's chocolate syrup together in a microwave-safe bowl in 30-second intervals, stirring between each interval until completely smooth.
Once the cakes are done, let them cool in the pans for 10 minutes, then transfer to a wire rack to cool completely. This resting period prevents cracking when you add the filling. While the cakes cool, pour the melted chocolate mixture into a piping bag fitted with a star tip. This is where the magic happens—you'll pipe the chocolate in a zigzag pattern over one of the cooled cake layers before assembling.
Assemble with Buttercream and Chocolate Swirls
In a stand mixer fitted with the paddle attachment, beat the 1 cup heavy whipping cream on medium speed until soft peaks form. Gradually add the 3 cups powdered sugar, mixing until smooth and fluffy. This buttercream should be thick enough to hold its shape but still pipeable—if it's too stiff, add a splash of milk to loosen it.
Place one cake layer on a serving plate and spread a generous layer of buttercream over the top. This is your base for the chocolate swirls. Using the piping bag with the melted chocolate mixture, pipe a zigzag pattern directly onto the buttercream. The contrast between the rich chocolate and creamy frosting creates that signature look.
Top with the second cake layer and spread another layer of buttercream on top and around the sides. Use a spatula to create smooth, clean edges. For extra decadence, pipe additional chocolate swirls on top of the buttercream before serving. Chill the cake in the refrigerator for 1 hour before slicing—this allows the flavors to meld and the layers to set properly.
Serve with Confidence
Slice the cake into 12 equal portions and serve immediately. Each slice should reveal those beautiful marbled layers and a perfect balance of fudgy cake and creamy frosting. The secret swirl of melted chocolate adds a rich, intense flavor that makes this cake unforgettable.
Here's the thing—this cake tastes even better the next day as the flavors deepen. Store any leftovers covered at room temperature for up to 3 days or in the refrigerator for up to 5 days. If you're feeling fancy, dust the top with a little extra powdered sugar right before serving—it adds a professional touch that elevates the presentation.
Pro Tips For Making Hershey'S Black Magic Cake
- Sift That Dry Mix: I learned this the hard way—skipping the double-sift with the 2.5 cups all-purpose flour, 0.75 cup cocoa powder, 1.5 tsp baking powder, and 0.5 tsp salt leaves lumps that turn into dense pockets in your cake. Use a fine-mesh sieve and do it twice. Trust me, your crumb will thank you.
- Room-Temp Butter Wins: The 1.5 cups unsalted butter needs to be soft but not greasy—press your finger into it, and it should leave a slight indent. If it’s cold, your cake will be dense; if it’s melted, you’ll lose air. Let it sit for 30-45 minutes before creaming, and you’ll get that light, fluffy texture.
- Don’t Overmix the Batter: Once you fold in the dry ingredients, stop mixing as soon as you see small flour streaks. Overmixing develops gluten, and your cake will turn tough instead of tender. I used to push it, thinking more mixing meant better results—wrong. Just combine until just combined.
- Pipe the Chocolate Fast: The melted 12 oz chocolate bars and 1 cup syrup needs to stay smooth and glossy for that perfect swirl. Work quickly once it’s melted—if it starts to thicken, reheat it in 10-second bursts. A piping bag with a star tip makes this easy, but don’t let it cool before piping, or you’ll regret it.
Troubleshooting this dish
Cake Layers Too Dense
If your cake layers come out dense instead of light and fudgy, it’s likely due to overmixing or incorrect baking time. I’ve found that mixing the batter just until the flour disappears prevents a tough texture—overmixing develops gluten and makes the cake heavy.
Bake until a toothpick comes out with a few moist crumbs, not wet batter. If your layers are still too dense, reduce the baking powder to 1 tsp and bake at 325°F for 35-40 minutes instead. 🔥
Chocolate Swirls Separating
The melted chocolate swirls pulling away from the batter happens when the chocolate cools too quickly. To fix this, let the melted 12 oz Hershey’s semi-sweet chocolate bars and 1 cup chocolate syrup cool slightly—just until warm, not hot—before swirling into the batter.
If the chocolate is too hot, it’ll cook the eggs in the batter and cause separation. Stir gently with a spatula in a figure-eight motion to blend seamlessly.
Buttercream Too Thin
A runny buttercream usually means your 1 cup heavy whipping cream wasn’t cold enough or you added too much powdered sugar. Chill your mixing bowl and beaters for 10 minutes before starting, and whip the cream to stiff peaks before adding the 3 cups powdered sugar.
If it’s still too thin, add 1 tbsp unsalted butter at a time until it holds shape. Avoid overmixing—stop as soon as it’s smooth.
Cracked Cake Layers
Cracks form when cakes cool too quickly or are handled too soon after baking. Let the cakes cool in the pans for 15 minutes instead of 10, then transfer to a wire rack.
Avoid touching the layers until they’re completely cool. If cracks appear during assembly, gently press them together with your fingers while spreading the buttercream—it’ll disguise the imperfections.
Frosting Not Holding Shape
If your buttercream won’t pipe or slumps after baking, it’s likely too warm or lacks stability. Chill the assembled cake in the refrigerator for 1 hour before decorating to firm it up. For extra hold, add 1 tbsp cornstarch to the powdered sugar before mixing.
You can also substitute 1/4 cup softened butter for some of the heavy cream to create a more structured frosting.
Nutrition facts
Frequently asked questions
Why does this cake need the swirl technique?
The swirl technique creates those signature chocolate ribbons that make this cake legendary! The melted Hershey's semi-sweet chocolate bars and chocolate syrup are piped onto the buttercream layer before the second cake layer goes on, giving each slice a rich chocolate surprise. It's what sets this cake apart from regular chocolate cakes.
Can I make this cake without a stand mixer?
You can use a hand mixer for the buttercream—just whip the heavy whipping cream until soft peaks form, then gradually add the powdered sugar. Mixing by hand takes a bit more elbow grease, but the results will be just as delicious. Just be patient and mix thoroughly for that perfect texture.
What if my buttercream is too thick or too thin?
If it's too thick, add 1 teaspoon milk at a time until it's smooth. If it's too thin, chill the bowl and beaters for 10 minutes before mixing again. For extra stability, add 1 tablespoon unsalted butter to thicken it up. The key is to work with a cold bowl and cream for stiff peaks!
How do I prevent my cake from cracking?
Cracks happen when cakes cool too quickly. Let them cool in the pans for 15 minutes instead of 10, then transfer to a wire rack. Avoid touching the layers until completely cool. If cracks appear during assembly, gently press them together while spreading the buttercream to disguise them.
Can I substitute ingredients if I don't have Hershey's products?
For the cocoa powder, Ghirardelli works well, but stick to Hershey's chocolate syrup for that authentic flavor. If you're out of Hershey's semi-sweet chocolate bars, use Ghirardelli squares. For the buttercream, Domino powdered sugar gives the best texture—just avoid generic brands that may contain cornstarch fillers.
