
These chocolate keto cupcakes are going to blow your mind. You won’t believe that anything made with coconut flour can be this tender and delicious. Perfect with your favorite sugar-free frosting!

It’s crazy to think that these keto cupcakes were one of the first low carb recipes I ever made. I originally published them in October of 2010, when my youngest child was having her first birthday. Now she’s a teenager! Oh how time flies.
But amazingly, this recipe has stood the test of time and is one of my favorite keto cake recipes. While my baking skills have improved and my methods and ingredients have changed, these chocolate keto cupcakes remain virtually unchanged.
It’s such a solid recipe that I have used it for multiple other cakes, including Keto Chocolate Orange Cake and Samoa Bundt Cake. Even my Keto Chocolate Donuts are based on this batter!
I made them again recently so I could get some new photos. And one bite reminded me just how much I love them!

Why this recipe is so awesome
Many people think that coconut flour can’t possibly make good baked goods. But I heartily disagree. Although baking with coconut flour takes some getting used to, it can result in cakes that rival those from a bakery.
And these keto cupcakes are proof. Light and fluffy, but still moist and flavorful, they defy the odds. It all comes down to a few tricks, like using enough eggs and oil. And a little protein powder helps them rise delightfully.
It’s a very versatile recipe, as you can pair it with your favorite sugar free frosting. And you can use it to make larger cakes as well. They also freeze really nicely.
Best of all, each cupcake has only 2.4g net carbs!
Reader reviews
“Oh my goodness! These cupcakes are great! Perfect crumb, rose nicely, and the taste – excellent!!!!” — Penny
“Made these tonight for Easter. Ate without frosting of any kind. My very first attempt at keto baking and the first time making cupcakes from scratch. So delicious!! They came out perfectly!” — Amanda
“Oh my word! These are insanely good and my teenage daughter who is not low carb asks for another batch as she’s eating the last one! Everyone loves these and I love the fact that me and OH can indulge in a sweet treat and still lose/maintain weight and feel great! Thanks so much for all your recipes. — Shona
Ingredients you need

- Coconut flour: You cannot substitute any other flour for coconut flour, as it’s very unique and bakes very differently. However, I have other cupcake recipes that use nut flours instead. You can also use my Keto Devil’s Food Cake recipe and make cupcakes with it.
- Sweetener: Most granular sweeteners work in this recipe but keep in mind that allulose may make the cupcakes brown faster.
- Cocoa powder: For a deeper, richer chocolate flavor, use dark cocoa or Dutch process cocoa.
- Protein powder: This is optional but it really does help the cupcakes rise better and be fluffier. You can use whey protein, egg white protein, or plant-based protein. Collagen peptides will not work here. You can also use chocolate or vanilla protein powder, if you don’t have unflavored.
- Eggs: Coconut flour requires a lot of eggs for structure, so don’t try to skimp!
- Cold coffee or water: I like coffee because it enhances the chocolate flavor, but water works too.
- Pantry staples: Butter or oil, vanilla extract, baking powder, and salt.
Step-by-step directions

1. Whisk the dry ingredients: In a large bowl, whisk together the coconut flour, sweetener, cocoa powder, protein powder, baking powder, and salt.
2. Add the wet ingredients: Stir in the eggs, butter, and vanilla extract until well combined.
3. Add liquid slowly: Stir in the coffee about 1/4 cup at a time until your batter is thick but scoopable.
4. Bake the cupcakes: Divide the batter evenly among 12 muffin cups lined with parchment or silicone liners. Bake at 350ºF for 20 to 25 minutes or until the tops are just firm to the touch.
5. Let cool: Remove from the oven and let the cupcakes cool completely in the pan.
6. Frost and decorate as desired!

Expert tips
The hardest thing about working with coconut flour is that it varies brand to brand. Some are super absorbent and others are less so, so you need to adjust the liquid accordingly. This is why I recommend adding just a little at a time. The description of the batter should guide you to know when it’s ready.
Do not over-bake these keto cupcakes. Whenever someone says they turned out dry, I know they let them bake too long. Always set the timer for the lower end of the suggested baking time, and then check very frequently. Once the tops are just firm to the touch, remove them from the oven.
How to frost and decorate

You have many delicious options for frosting these keto cupcakes. I have provided a delicious sugar-free espresso frosting in the recipe, but you certainly aren’t limited to that! A few other ideas:
- Keto Chocolate Frosting
- Keto Strawberry Frosting
- Cookies and Cream Frosting
- Peppermint Frosting
- Peanut Butter Frosting
You could also eat them plain or top with a little keto vanilla ice cream!

Frequently Asked Questions
These keto chocolate cupcakes have 5.6g carbs and 3.2g fiber unfrosted, so they have 2.4g net carbs per cupcake. With the frosting listed in the recipe, they have 6.2g of carbs and 3.2g of fiber.
Coconut flour is an excellent ingredient for keto recipes because it is low in carbs and high in fiber. It is also completely gluten-free and nut-free. It is highly unusual in the way it absorbs eggs and liquid, so you have to learn how to use it properly. For more information, read my article on Baking with Coconut Flour.
Cupcakes like these are fine on the counter for up to three days. You can also store them in an airtight container the refrigerator for a week or in the freezer for several months.


Keto Cupcakes Recipe
Ingredients
Cupcakes
- 2/3 cup (80 g) coconut flour
- 2/3 cup (121.33 g) Swerve Sweetener, or other granular sweetener
- 6 tbsp (30.43 g) cocoa powder
- 1/4 cup (27 g) whey protein powder, chocolate, vanilla, or unflavored
- 2 tsp baking powder
- 1/2 tsp salt
- 6 large eggs
- 1/2 cup (113.5 g) butter, melted
- 1 tsp vanilla extract
- 1/2 cup (118.29 ml) leftover coffee or water, more if needed
Espresso Buttercream:
- 2 tbsp hot water
- 2 tsp instant espresso powder, or instant coffee
- 1/2 cup (118.29 ml) heavy whipping cream
- 6 tbsp (85.21 g) butter, softened
- 4 oz (113.4 g) cream cheese, softened
- 1/2 cup (62.5 g) Swerve Confectioners, or other powdered sweetener
Instructions
Cupcakes
- Preheat the oven to 350ºF and line a muffin tin with parchment or silicone liners
- In a large bowl, whisk together the coconut flour, sweetener, cocoa powder, protein powder, baking powder, and salt. Stir in the eggs, butter, and vanilla extract until well combined.
- Stir in the coffee about 1/4 cup at a time until the batter is thick but easily scoopable.
- Divide the batter evenly among the prepared muffin cups. Bake 20 to 25 minutes or until the tops are just firm to the touch.
- Remove from the oven and let cool completely in the pan.
Espresso Buttercream
- In a small bowl, stir together the hot water and espresso until coffee dissolves. Set aside.
- With an electric mixer, whip the cream until it forms stiff peaks. Set aside.
- In a medium bowl, beat the butter, cream cheese, and sweetener together until creamy. Add the coffee mixture and beat until combined. With a rubber spatula, fold in the whipped cream carefully until well combined.
- Spread the frosting on cooled cupcakes with a knife or offset spatula, or pipe on with a decorating bag.
Video
Notes
Nutrition
Nutritional Disclaimer
Please note that I am not a medical or nutritional professional. I am simply recounting and sharing my own experiences on this blog. Nothing I express here should be taken as medical advice and you should consult with your doctor before starting any diet or exercise program. I provide nutritional information for my recipes simply as a courtesy to my readers. It is calculated using MacGourmet software and I remove erythritol from the final carb count and net carb count, as it does not affect my own blood glucose levels. I do my best to be as accurate as possible but you should independently calculate nutritional information on your own before relying on them. I expressly disclaim any and all liability of any kind with respect to any act or omission wholly or in part in reliance on anything contained in this website.
Free Bonus: Secrets to Keto Baking!
Sign up for your favorite recipes delivered straight to your inbox plus get our FREE bonus: Secrets to Keto Baking!




Oh my goodness! These cupcakes are great! Perfect crumb, rose nicely, and the taste – excellent!!!!
sorry, I meant what baking time and temperature should I set the oven to if I use a 9×9 cake pan instead of cupcake pan?
Hi, I would like to make this chocolate coconut flour recipe as a birthday cake. Can I use a 9×9 cake pan instead of cupcake pan? if so, what temp & time should I use to bake in a square pan?
Has anyone made this into a cake? I’m wondering if there was a time and temp for a 9×9 square, 9×13 rectangular, or any size of a circular pan?
I’ve used it many times for cake: https://alldayidreamaboutfood.com/keto-chocolate-orange-cake/
https://alldayidreamaboutfood.com/keto-cookies-and-cream-cake/
can you use 2% milk instead of almond milk?
Yes, that works… it just adds a bit of carbs.
I loved these and feel they taste better the next day. I used coconut cream mixed with cocoa and swerve for a delicious icing.
Excellent!
These cupcakes and frosting are the best!
The flavor was really nice and the size of the muffin was really nice. I baked for 20 minutes and a toothpick came out clean but when they were taken out of the oven to cool they sunk a bit. I found the texture to be quite dry (I don’t do icing); which can happen with coconut flour. I’ll keep looking.
I just made these cupcakes and they lived up to most of your promises. The cupcakes are very fluffy and full of chocolate flavor.
The instructions are clearly written and detailed so you should have wonderful results. I only had coconut flour available for baking at my mom’s home, where I am visiting. I am not a fan coconut baked goods but needs must.
I used Swerve confectioners sweetener. However I think it could have used more sweetness because I didn’t make the frosting. It was so nice to have a chocolatey treat while I am away from my normal baking ingredients
Thanks Carolyn
I do not see how the 6.5 carbs for each cupcake can be accurate. The Swerve Sweetner you are using is 4 grams of carbs per tsp. You are using 2/3 cup which is 32 teaspoons equaling 128 grams of carbs. The coconut flour is 9 grams of carbs per 2 tablespoons. You are using 2/3 cup. That is 10.6 tablespoons equaling 47.7 grams of carbs. The cocoa powder is another 21 grams for the 7 tablespoons. That is a total of 196.7 total carbs divided by 12 cupcakes equals 16.4 carbs. That is without your frosting!
Hi Trev… I am very clear in my nutritional disclaimer at the bottom of each blog post. I do NOT count erythritol at all for any recipe because it has zero impact on blood sugar. This is standard practice for most keto recipes. Please research it.
I love this recipe! I have missed cupcakes, and this one turned out fabulous!! I’m looking for a vanilla version to add to my folder. Would your “Coconut Flour Cupcakes with Buttercream” be the best match?
Thank you!
Wendy
Is Swerve the same as Stevia?
No, not at all. https://swervesweet.com/faqs
These cupcakes are excellent. I have baked them a few times now. I added half a teaspoon of Guar gum in my last batch and it helped them rise even better. I would say they deserve a 10/10.
Good to know!
Can I substitute egg whites instead of regular eggs ?
I can’t see why not but you need to make sure it’s the same amount of egg in total.
Hey Carolyn!! I noticed that you are using protein powder in many of your cake recipes now…would it be a good idea to add some to these? Also, Thanks so much for ALL you do!!
Not this recipe, no. It was designed to be without it and they rise nicely as it is. If you do choose to use it, don’t use more than 1/4 cup.
Hi there, I’m wondering if I could substitute almond flour for the coconut. The person I’m making these for is allergic to coconut and I really want a delicious chocolate cupcake recipe!
This recipe is based on coconut flour, which is SO different from almond flour that they cannot be swapped. It would be a disaster. However, you can use this recipe for an almond flour based cupcake. Just switch out the irish cream for heavy cream. https://alldayidreamaboutfood.com/keto-irish-cream-cupcakes/
Can I use black cocoa in this recipe?
Absolutely!