A good carrot cake is moist, tender and gently spiced, with flecks of sweet carrot in every bite and a thick layer of tangy cream cheese frosting on top. This is my favorite version, a two-layer cake made with oil, brown sugar and toasted pecans, and it stays soft for days.
Below you will find why this homemade carrot cake works, the right way to grate carrots, step-by-step baking and frosting instructions, and tips for a smooth, sturdy frosting. I also share variations, a troubleshooting table and make-ahead advice. The full printable recipe card is waiting at the bottom of the post.

Why This Carrot Cake Recipe Works
Carrot cake has a reputation for being dense or greasy, but the right balance of ingredients gives you a light, moist crumb that holds up to a generous layer of frosting. Here is what makes this recipe reliable.
- Oil instead of butter. Oil stays liquid at room temperature, so the cake stays moist and tender even straight from the refrigerator.
- Brown and white sugar. Brown sugar adds a caramel flavor and extra moisture, while white sugar keeps the crumb light.
- Finely grated carrots. Small shreds melt into the batter and release moisture evenly as the cake bakes.
- Warm spices. Cinnamon, nutmeg and a little ginger give the cake a cozy flavor without overpowering the carrots.
- Toasted pecans. Toasting brings out their nutty flavor and keeps them crisp inside the cake.
The cream cheese frosting is just sweet enough, with a tang that balances the spiced cake. It is firm enough to pipe and spread, yet soft and creamy when you take a bite.
It is also a forgiving recipe for beginners. There is no creaming of butter, no folding of whipped egg whites and no tricky timing. If you can whisk two bowls together and grate a few carrots, you can bake a carrot cake that looks and tastes like it came from a neighborhood bakery.
Ingredients You Will Need
This cake uses everyday baking staples plus a pound of fresh carrots. Measure the flour carefully and grate the carrots yourself for the best texture.
- All-purpose flour: Spoon and level it. Too much flour makes a dry cake.
- Baking powder and baking soda: The two leaveners together give a tender, even rise.
- Spices: Ground cinnamon, nutmeg and ginger. Use fresh jars for the best aroma.
- Eggs: Four large eggs at room temperature for structure and richness.
- Neutral oil: Vegetable, canola or light olive oil all work well.
- Sugars: Granulated sugar and packed light brown sugar.
- Carrots: About 1 pound of whole carrots, peeled and finely grated, which gives roughly 3 cups.
- Pecans: Chopped and toasted. Walnuts are a great swap.
- For the frosting: Full-fat brick cream cheese, softened butter, powdered sugar, vanilla and a pinch of salt.
A note on carrots: medium carrots are sweeter and less woody than very thick ones, and they are easier to grate. Peel them, trim the ends and grate them just before mixing. If you are using a food processor, pulse the shreds a few times afterward so there are no long strands that might clump together in the batter.
How to Make Carrot Cake
The batter is mixed by hand in two bowls, no mixer needed. You will only need a mixer for the frosting.
- Prepare the pans. Heat the oven to 350°F (175°C). Grease two 9-inch round cake pans, line the bottoms with parchment and grease the parchment.
- Toast the pecans. Spread the pecans on a baking sheet and toast for 6 to 8 minutes until fragrant. Cool and chop.
- Mix the dry ingredients. Whisk the flour, baking powder, baking soda, salt, cinnamon, nutmeg and ginger in a medium bowl.
- Mix the wet ingredients. In a large bowl, whisk the eggs, oil, both sugars and vanilla until smooth and slightly thickened, about 1 minute.
- Combine. Add the dry ingredients to the wet and stir with a spatula just until a few streaks of flour remain. Fold in the grated carrots and 3/4 cup of the pecans until evenly combined.
- Bake. Divide the batter between the pans and bake for 28 to 34 minutes, until the tops spring back when pressed and a toothpick in the center comes out clean.
- Cool. Cool in the pans for 15 minutes, then turn out onto a wire rack, peel off the parchment and cool completely, about 1 1/2 hours.
- Make the frosting. Beat the cream cheese and butter on medium speed until smooth. Add the powdered sugar, vanilla and salt and beat on low, then medium, until fluffy, about 2 minutes.
- Assemble. Place one layer on a plate and spread with about 1 1/4 cups frosting. Top with the second layer, then frost the top and sides. Press the remaining pecans around the bottom edge or sprinkle them on top.

Make sure the layers are completely cool before frosting. Even slightly warm cake will melt cream cheese frosting and make it slide.
Tips for the Best Homemade Carrot Cake
- Weigh your flour if you can. 250 grams is exactly right for this recipe.
- Do not squeeze the grated carrots. Their juice is part of what keeps the cake moist.
- Stir the batter gently once the flour is in. Overmixing can make the cake tough and dense.
- Level domed layers with a serrated knife before stacking for a neat, stable cake.
- Chill the frosted cake for 30 minutes before slicing for clean, tidy pieces.
- Use softened, not melted, butter and cream cheese for the frosting. Both should give slightly when pressed.
If you love spiced fall bakes, try my easy cinnamon apple cake, a loaf of moist spiced pumpkin bread for breakfast, or a slice of southern Italian cream cake with coconut and pecans. You will find many more cakes in my dessert recipe collection.
The Secret to Thick Cream Cheese Frosting
Cream cheese frosting can turn runny if the ingredients are too warm or overbeaten. A few simple habits keep it thick and spreadable.
- Use brick cream cheese. Tub-style spreads contain more water and make the frosting soft.
- Start cool. Let the cream cheese and butter soften for about 30 to 45 minutes, not all afternoon.
- Beat briefly. Once the sugar is in, stop as soon as the frosting looks smooth and fluffy.
- Chill if needed. If the frosting feels loose, refrigerate it for 15 to 20 minutes and stir before using.
This recipe makes enough frosting to fill and cover a two-layer cake generously. If you like a thinner coat, you will have a little left for a few cupcakes or graham cracker sandwiches.
Sheet Cake and Cupcake Options
Not in the mood to stack layers? The same batter bakes beautifully in other pans. For a 9×13-inch sheet cake, bake for 35 to 42 minutes and frost right in the pan, which makes it easy to carry to a potluck.
For cupcakes, fill lined muffin cups two-thirds full and bake for 18 to 22 minutes. You will get about 24 cupcakes, and the frosting will cover them with a generous swirl. A Bundt pan also works: grease it well and bake for 45 to 55 minutes, then finish with a thick cream cheese glaze.
Whichever pan you choose, use the same toothpick test and let the cake cool completely before frosting. Sheet cakes and cupcakes also freeze well unfrosted, so you can bake ahead for a busy weekend.
Easy Variations
- Pineapple carrot cake: Fold in 1/2 cup well-drained crushed pineapple for extra moisture and a bright, tropical note.
- Raisins or golden raisins: Soak 1/2 cup in warm water for 10 minutes, drain and fold in with the carrots.
- Coconut: Add 1/2 cup sweetened shredded coconut to the batter.
- Nut-free: Leave out the pecans and decorate with candied carrot ribbons or a sprinkle of cinnamon.
- Brown butter frosting: Brown the butter, chill it until soft and spreadable, then use it in the frosting for a nutty flavor.
- Orange zest: Add 1 tablespoon finely grated orange zest to the batter and 1 teaspoon to the frosting for a bright, fresh flavor that pairs beautifully with the spices.
Common Mistakes and How to Fix Them
| Problem | Likely cause | How to fix it |
|---|---|---|
| Dense, heavy cake | Too much flour or overmixing | Spoon and level or weigh the flour and fold gently. |
| Dry cake | Overbaked or pre-shredded carrots | Start checking at 28 minutes and grate fresh carrots finely. |
| Sunken middle | Underbaked or oven door opened early | Bake until the center springs back and avoid opening the oven in the first 20 minutes. |
| Runny frosting | Ingredients too warm or tub cream cheese | Use brick cream cheese, soften only briefly and chill the frosting if needed. |
| Layers stick to the pan | Pans not lined | Grease the pans and line the bottoms with parchment. |
Make Ahead, Storage and Freezing
Because cream cheese frosting is perishable, store the frosted carrot cake in the refrigerator. The USDA guidance on leftovers and food safety recommends refrigerating perishable foods within 2 hours. Covered, the cake keeps for up to 5 days and stays moist thanks to the oil. Let slices sit out for 20 minutes before serving for the softest texture.
To work ahead, bake the layers up to 2 days early, wrap them tightly and refrigerate, or freeze them for up to 2 months. The frosting can be made 3 days ahead and chilled, then rewhipped briefly. You can also freeze individual frosted slices on a tray, then wrap and store them for up to 1 month.
Frequently Asked Questions
Why is my carrot cake dry?
The most common reasons are too much flour, overbaking or using thick pre-shredded carrots. Measure carefully, grate the carrots finely and start checking early.
Should I squeeze the liquid out of grated carrots?
No. The juice from the carrots adds moisture to the cake. Just grate them and fold them in.
Does carrot cake need to be refrigerated?
Yes, once it has cream cheese frosting. Keep it covered in the refrigerator for up to 5 days.
Can I make carrot cake without nuts?
Absolutely. Leave the pecans out of the batter and decorate the top with a light dusting of cinnamon instead.
Can I use butter instead of oil?
You can use melted butter, but the cake will be firmer when cold. Oil keeps carrot cake soft and moist even straight from the refrigerator.
Ready to bake? Here is the full printable carrot cake recipe with exact measurements, baking times and estimated nutrition.

Carrot Cake with Cream Cheese Frosting
Ingredients
Method
- Heat the oven to 350°F (175°C). Grease two 9-inch round pans, line the bottoms with parchment and grease the parchment.
- Toast the pecans on a baking sheet for 6 to 8 minutes until fragrant, then cool and chop.
- Whisk the flour, baking powder, baking soda, salt, cinnamon, nutmeg and ginger in a medium bowl.
- In a large bowl, whisk the eggs, oil, granulated sugar, brown sugar and vanilla for 1 minute until smooth.
- Stir the dry ingredients into the wet until a few streaks remain, then fold in the carrots and 3/4 cup of the pecans.
- Divide between the pans and bake for 28 to 34 minutes, until the tops spring back and a toothpick comes out clean.
- Cool in the pans for 15 minutes, then turn out onto a rack and cool completely.
- Beat the cream cheese and butter until smooth. Add the powdered sugar, vanilla and salt and beat until fluffy, about 2 minutes.
- Spread about 1 1/4 cups frosting over the first layer, add the second layer, then frost the top and sides. Decorate with the remaining pecans and chill 30 minutes before slicing.
Notes
I hope this carrot cake becomes the one your family requests for birthdays, Easter and every gathering in between. If you bake it, please leave a comment and a star rating below and tell me which add-ins you chose. Happy baking, friends. Chef Amber
Free email bonus
30-Minute Meals
Loved this recipe? Get my collection of fast, family-favorite dinners, plus new seasonal recipes straight to your inbox.
