Homemade Chocolate Cake – a two layer moist chocolate cake made from scratch, slathered with homemade chocolate frosting. A perfect cake recipe for any occasion!
Baking is one of my favorite things to do, so you will find a great variety of made from scratch cake recipes on my site. Have you tried my White Chocolate Raspberry Bundt Cake or my Butterfinger Cake yet?

Moist Chocolate Cake from Scratch
I’ve tried several homemade chocolate cake recipes over the years, but never found a recipe for two layer cake that I loved. I prefer cakes that are dense and tender, more like brownies than cake from a cake mix.
I finally found a winner! This made from scratch chocolate cake turns out perfectly fudgy and moist.
Another great thing about this cake recipe is that it calls for simple ingredients that I always have on hand. Nothing beats being able to make one of your favorite cakes without having to run to the store for ingredients.
(To skip my tips and tricks and just see the recipe card, simply scroll to the bottom of the post.)
HOW TO MAKE HOMEMADE CHOCOLATE CAKE
Ingredients needed for cake:
- all purpose flour
- granulated sugar (regular baking sugar)
- unsweetened cocoa powder (I used regular Hershey’s cocoa)
- baking powder
- baking soda
- salt
- milk (I used 2%, but any milk should work.)
- oil (I used vegetable oil)
- large eggs
- vanilla extract
- boiling water
- Making cake from scratch is easier than you think! You don’t even need a mixer for this cake, just a good sturdy whisk. First up you whisk together the dry ingredients in a mixing bowl.
- Then whisk in milk, oil, eggs, and vanilla. To finish it off, you pour in a cup of boiling water and stir everything together.
- You will end up with a very thin better. Pour the batter into two well greased 9″ round pans that have been lined with parchment paper. Bake at 350° for 30-35 minutes.
- Let the cakes cool for about 10 minutes in the pan, then invert onto cooling racks.

TRICK FOR MAKING MOIST CAKE:
I learned this tip from my friend Ashlee, who is a rockstar at cake making. While the cake is still warm, wrap each layer tightly in plastic wrap. Place into the freezer and freeze for several hours or overnight.
All that steam will be trapped in the cake, ensuring that you are not left with a dry cake! The first time I tried it, I was worried that the outside of the cake would be soggy, but nope, it works like a charm.

Another bonus is that the cake is easier to stack while it is still frozen. Place the first layer on a cake stand or platter. Spread a layer of frosting over the top. I usually use about a cup of frosting.

Add the second layer. Frost the top and sides of the cake.
Keep in mind that because the cake is frozen, the frosting will set up very quickly and lose it’s creamy texture. So work fast!
As the cake thaws, the frosting will soften up again. I was in a hurry to take photos, so my cake was still cold. After another hour, the frosting and cake were both softer.
PRO TIP: Place pieces of parchment or waxed paper around the bottom edge of the cake. When you are done, pull them out and you are left with a clean cake stand!
Easy Chocolate Frosting
I always make my chocolate frosting from scratch. It is so simple, only takes a few minutes, and tastes infinitely better than the stuff in a jar. Plus it’s made from pure ingredients like butter and milk, and is free of all the chemicals in store bought frosting.
You probably already have all the ingredients on hand!
Ingredients needed for frosting:
- butter (softened to room temperature)
- cocoa powder (Just like the cake, I use regular Hershey’s cocoa.)
- powdered sugar (also known as confectioner’s sugar)
- vanilla extract
- salt (I always add a pinch of salt to my frosting to offset the sweetness)
- milk (you can substitute cream or evaporated milk)
You can either use a hand mixer or a Kitchenaid to make frosting. I usually use a hand mixer because it’s easier than hauling out my big mixer.
You want to make sure that your butter is perfectly soft. Unlike butter for cookies, I think it’s fine to soften it in the microwave.
Combine all of your ingredients in a mixing bowl, starting with the smallest amount of milk. Beat till smooth adding more milk as needed. Spread over your cake as directed above.
If you want to add sprinkles, make sure you add them before the frosting sets up.

How to store Chocolate Cake?
Leftover cake needs to be covered so it doesn’t dry out. My cake stand has a cover, but a large bowl will sometimes work if you don’t have one. It will last at room temperature for 3-4 days, or in the refrigerator for 4-5. I think it’s best to let it come to room temperature before serving, but some of my family members like it served cold.
Can I freeze chocolate cake?
Yes, you can freeze this cake. It’s easiest to freeze the cake before it’s frosted. Wrap each layer tightly in plastic wrap and place in the freezer. It will keep for 3-4 months.
When ready to serve, you can either frost it frozen like I did, then let it thaw before serving, or let it thaw and then freeze it.
You can freeze the cake after it is frosted, you just need a large space in your freezer. After frosting the cake on a platter, place the platter on a cookie sheet. Stick it all in the freezer and freeze for 3-4 hours, or until the frosting is hardened. Remove it from the freezer and wrap it tightly with plastic wrap, then place back in the freezer.
It will keep for 2-3 months in the freezer. Let it thaw for several hours before serving.
How can I make this cake gluten free?
-You can substitute cup for cup gluten free flour in place of the all purpose flour. The cake will be more fragile, so I definitely recommend using the freezing method if you go this route.
Or you could just make my Amazing Chocolate Chip Cheesecake Cookies, or Flourless Chocolate Cake.
Can I make this recipe into cupcakes?
Yes, you can make chocolate cupcakes instead. Fill 24 paper lined muffin pans and divide batter evenly between them. Bake at 350 degrees for 18-22 minutes, or until toothpick inserted in the center comes out clean. Cool completely before frosting.
CHOCOLATE CAKE VARIATIONS:
- For an even more dense chocolate flavor, use a cup of hot coffee in place of the boiling water, or stir in 2-3 teaspoons of espresso powder.
- Stir some peppermint extract into the frosting and you’ll have a mouthwatering chocolate mint cake. For even more mint flavor, stir some peppermint extract into the cake as well.
- Sprinkle some mini chocolate chips over the top of the frosted cake, or top with chocolate curls.
- Switch up the flavor of frosting. We love the combination of chocolate with peanut butter frosting, but you could also use vanilla buttercream, strawberry buttercream, coconut, or salted caramel. And of course German chocolate frosting is always tasty.
- Sprinkle some coconut, toasted nuts, or heath bits on each layer. Get creative! This cake is a great base for just about any topping.


Homemade Chocolate Cake
Equipment
- Cuisinart Hand Mixer
- Stainless Steel Wire Whisk Set, Dishwasher Safe, 3 Piece
- Chicago Professional Non-Stick Round Cake Pan, 9-Inch
Ingredients
Cake
- 2 cups all purpose flour
- 2 cups sugar
- ¾ cup cocoa powder
- 2 tsp baking powder
- 1 tsp salt
- 1 cup milk
- ½ cup oil
- 2 eggs
- 2 tsp vanilla
- 1 cup boiling water
Chocolate Frosting
- ½ cup butter softened
- ½ cup cocoa powder
- 4 cups powdered sugar
- 1 tsp vanilla
- 1 pinch salt
- 6-8 Tbsp milk
Instructions
- Line two 9" round pans with parchment paper and spray with non-stick spray. Preheat oven to 350°.
- Whisk together the flour, sugar, cocoa, baking powder, baking soda, and salt in a large mixing bowl.
- Whisk in the milk, oil, eggs, and vanilla till smooth. Stir in the boiling water, mixing till smooth.
- Divide batter evenly between the two pans. Bake at 350° for 30-35 minutes or till toothpick inserted in the center comes out clean. Cool for 10 minutes in the pans, then invert onto cooling racks.
- Cool completely. (I wrap each cake in plastic wrap and freeze.) Place one cake on a cake stand or serving tray. Spread about a cup of frosting on the top. Place the other cake on top. Frost sides and top of the cake. Serve immediately or cover and let sit overnight.
- For frosting, beat all ingredients in a bowl till smooth, adding enough milk to get a spreadable consistency.