Moist Carrot Cake
Our moist carrot cake recipe is packed with fresh carrots, spices, and a sweet cream cheese frosting. It’s easy to make and perfect for your best get-togethers!

There’s carrot cake, and then there’s this carrot cake. It’s super moist, full of warm spices, a bit of pineapple and coconut, then topped with a thick layer of cream cheese frosting.
It’s the kind of cake you can bring to Easter, birthdays, potlucks, or wherever people like good dessert. And trust me, it will disappear fast.
What makes this carrot cake so good?
It’s all about the right mix of ingredients. This cake has finely grated carrots, crushed pineapple for extra moisture, and oil instead of butter for a soft, tender crumb.
I use a combination of granulated sugar and brown sugar for sweetness, and a blend of cinnamon, ginger, and nutmeg gives it that classic flavor.
Flour and eggs give the cake structure, while vanilla rounds everything out.
I usually stir in chopped pecans and shredded coconut, too. These ingredients are totally optional, but they add nice texture.

Butter vs. oil
If you want to swap the oil for butter, you can. Just know the cake will be a little drier. The flavor is more buttery, but you lose some of the softness.
I recommend going half oil, half butter if you want the buttery flavor while keeping the soft texture.
About the cream cheese frosting
Cream cheese frosting is a must in my book. Mine starts with two blocks of cream cheese, a full cup of butter, powdered sugar, vanilla, and a pinch of salt. It’s thick, smooth, and easy to spread.
I go heavy on the frosting, especially when I’m layering two 9-inch round cakes. If you’re making a single 9×13-inch cake or prefer a lighter layer, you can easily cut the frosting in half. It’ll still be enough to cover the top.

Tips before you bake
- Use a box grater or food processor for the carrots. You want them finely grated so they’re easy to mix into the batter.
- Make sure to drain the pineapple really well. Extra liquid can throw off the texture and the cake won’t bake correctly. I like to place the pineapple in a mesh sieve over a bowl to drain while I’m prepping the other ingredients.
- You can bake this in a 9×13-inch pan or two 9-inch round pans. Just grease and flour them well.
- Let the cake cool completely before frosting. Otherwise, the cake will melt the frosting and cause it to separate.
How to Store Leftovers
Store leftovers in an airtight container in the fridge for up to 5 days.
You can also freeze the cake layers without frosting. Just wrap them tightly in plastic wrap and foil. They’ll stay good for about 2 months.


Ingredients
For the Cake:
- 2 cups all-purpose flour
- 1 ½ teaspoons baking powder
- 1 teaspoon baking soda
- 1 teaspoon salt
- 1 ½ teaspoons ground cinnamon
- ½ teaspoon ground ginger
- ¼ teaspoon ground nutmeg
- 1 cup granulated sugar
- ½ cup packed brown sugar
- 1 cup vegetable oil
- 4 large eggs
- 2 teaspoons vanilla extract
- 2 cups finely grated carrots, about 4 medium carrots
- ½ cup crushed pineapple, drained
- ¾ cup chopped pecans, or walnuts (optional)
- ½ cup shredded coconut, optional
For the Frosting:
- 16 ounces block-style cream cheese, softened
- 1 cup unsalted butter, softened
- 6 cups powdered sugar
- 2 teaspoons vanilla extract
- Pinch of salt
Instructions
To Make the Cake:
- Preheat the oven to 350°F (175°C). Grease and flour a 9×13-inch pan or two 9-inch round pans.
- In a large bowl, whisk together the flour, baking powder, baking soda, salt, cinnamon, ginger, and nutmeg.2 cups all-purpose flour1 ½ teaspoons baking powder1 teaspoon baking soda1 teaspoon salt1 ½ teaspoons ground cinnamon½ teaspoon ground ginger¼ teaspoon ground nutmeg
- In another bowl, whisk the granulated sugar, brown sugar, oil, eggs, and vanilla until smooth.1 cup granulated sugar½ cup packed brown sugar1 cup vegetable oil4 large eggs2 teaspoons vanilla extract
- Add the wet ingredients to the dry ingredients and stir until just combined.
- Fold in the grated carrots, drained pineapple, nuts, and coconut if using.2 cups finely grated carrots½ cup crushed pineapple¾ cup chopped pecans½ cup shredded coconut
- Pour the batter into the prepared pan(s).
- Bake for 35–40 minutes (9×13-inch pan) or 30–35 minutes (9-inch rounds), or until a toothpick inserted in the center comes out clean.
- Let the cake cool completely before frosting.
To Make the Frosting:
- In a large bowl, beat the cream cheese and butter until smooth.16 ounces block-style cream cheese1 cup unsalted butter
- Add the powdered sugar and salt. Beat until creamy and spreadable then add the vanilla.6 cups powdered sugar2 teaspoons vanilla extractPinch of salt
- Frost the cooled cake and enjoy.
Notes
- Servings: The calories listed are an approximation based on the ingredients in the recipe card and a serving size of 1 slice of cake assuming it’s sliced into 16 equal slices. Actual calories will vary.
- Slices: You will get more slices by baking this in a 9×13-inch cake.
- Frosting: I use quite a bit of frosting. You may not need as much (especially if you use a 9×13-inch pan), so feel free to half the amount if desired.
- Oil: If you’d prefer to use butter in place of oil, I recommend swapping half the oil for the same amount of softened or melted (cooled) butter.
- Storage: Store leftovers in an airtight container in the fridge for up to 5 days. You can also freeze the cake layers without frosting.