The BEST EVER Keto Chocolate Mug Cake

Annie Lampella @ Ketofocus

By Annie Lampella, Pharm.D.

Published August 26, 2020 • Updated August 21, 2026

Reader Rating
4.6 Stars (25 Ratings)

This post may contain affiliate links. See my disclosure policy.

Rich and fudgy with deep dark cocoa flavor, mixed in one mug and out of the microwave in 60 seconds. I have made this since I first started creating keto recipes, and it is still what I reach for when I need something sweet right now, with ingredients already in the pantry. What I learned is that it rises fast, so use a mug with room to spare or it overflows. Two minutes from craving to fork. 3.8g net carbs and 9.9g protein.

I have been making this chocolate mug cake since I first started creating keto recipes, and it is still the one I come back to when I need something sweet right now. Not tomorrow. Not after a trip to the store. Right now, with ingredients I already have in the pantry.

The base is simple: one egg, melted butter, almond flour, cocoa powder, and a little coconut flour for structure. That coconut flour matters more than you think. It absorbs liquid and gives the cake body so it does not turn into a puddle. I have tested this ratio dozens of times, and this combination gives you a center that is fudgy without being wet.

The sweetener you pick changes the texture. I use monk fruit for a lighter, more cakey crumb. But I have also made this with allulose, and allulose holds more moisture, so you get a denser, fudgier result. My reader Mike tried the same swap and confirmed it. If fudgy is your goal, go with allulose. If you like a little more lift, stick with monk fruit. Either way, the carb count stays the same.

This is also one of those recipes that takes well to add-ins. A teaspoon of peanut butter stirred into the batter before microwaving gives you something that tastes like a low carb peanut butter cup. Sugar-free chocolate chips on top work too. I have even done a dollop of whipped cream after it cools for two minutes, which makes the whole thing feel more like a real dessert. If you like the chocolate chip angle, try my chocolate chip version.

If this is your first time making one of these, use a 12-ounce mug or bigger. Anything smaller and the batter rises over the rim during cooking. I learned that the hard way. A wide, shallow mug also gives you more surface area for crispy edges, which I prefer over a tall narrow one.

For the microwave, 60 to 75 seconds is the window. I check mine at 60 and give the mug a gentle shake. If the center still wobbles, I add 10 more seconds. You want it set but not rubbery. Every microwave runs differently, so the shake test is more reliable than a fixed time.

I keep coming back to this because it scratches the itch without turning into a project. When you want something more involved, my easy keto chocolate cake is worth the extra effort. For variety without the commitment, I rotate between this, my red velvet version, and the pumpkin version depending on my mood.

How to make it

Grab a 12-ounce or larger microwave-safe mug and add all the dry ingredients first: almond flour, cocoa powder, coconut flour, baking powder, sweetener, and a pinch of salt. Give those a quick stir so the leavening is evenly distributed. Then crack in the egg, pour in the melted butter, and mix until smooth. Scrape the sides down so there are no dry pockets hiding at the bottom.

Microwave on high for 60 seconds, then give it a gentle shake. If the center wobbles, add 10 to 15 more seconds. I find 65 seconds is my sweet spot, but every microwave is different, so trust the shake test over the clock. Once it is set, let it cool in the mug for a minute or two before eating. The same technique works for my birthday version too.

Youtube
Discover More Keto Recipes on Our Channel

Explore hundreds of keto recipe videos with step-by-step instructions, tips, and tricks to make keto easy.

Recipe
Print Pin

The BEST EVER Keto Chocolate Mug Cake

4.6 (25) Prep 1m Cook 1m Total 2m 1 servings

Ingredients

Step by Step Instructions

1
Add the ingredients

Add all ingredients to a mug or microwave safe small bowl.

mini cake ingredients in a white coffee mug
2
Mix it

Mix together until combined.

chocolate cake mixed in a white mug
3
Microwave it

Microwave for 60 to 75 seconds or until the cake has risen and is set in the middle. It should not be wobbly when you shake it. Remove from microwave to let cool.

small baked chocolate cake in a white mug
Tip Baking times may vary based on your microwave.
Nutrition Per Serving 1 mug cake
382 Calories
34.9g Fat
9.9g Protein
3.8g Net Carbs
9g Total Carbs
1 Servings
Nutrition disclaimer

The nutrition information provided is an estimate and is for informational purposes only. I am a Doctor of Pharmacy (Pharm.D.); however, this content is not intended to be a substitute for professional medical advice, diagnosis, or treatment. Always consult your physician or other qualified health provider before making any lifestyle changes or beginning a new nutrition program.

Your Macros. Your Recipes. Calculated in 60 Seconds.

Get personalized keto macros and instantly see which recipes fit your targets. No more guessing what to eat.

Get My Macros + Recipes →

Get weekly keto recipes from Annie.

Join the list and get new recipes delivered to your inbox every week.

The BEST EVER Keto Chocolate Mug Cake

Frequently Asked Questions

Can I bake this in the oven instead of the microwave?

I have done this in a ramekin at 350 degrees for about 12 to 14 minutes. The texture comes out more like a keto lava cake, with crispier edges and a softer center. I actually prefer the oven version when I have the time. Grease the ramekin first or it sticks.

Why did it overflow in the microwave?

Your mug is too small. I use a 12-ounce mug minimum because the batter rises quite a bit from the baking powder and egg. If you only have smaller mugs, split the batter between two of them and reduce the cook time by about 15 seconds each.

Can I make this without eggs?

I have tried it with a flax egg (1 tablespoon ground flax plus 3 tablespoons water, rested 5 minutes) and it works. The texture is denser and a little more crumbly, but it still holds together. I would not skip the egg replacement entirely or you end up with chocolate soup.

Is allulose better than monk fruit for this recipe?

They both work, but I get different textures from each. Allulose holds more moisture, so the cake comes out fudgier. Monk fruit gives a lighter, more traditional crumb. I go back and forth depending on whether I want fudgy or cakey that day. The carb count stays the same either way.

How can I make this dairy-free?

I swap the butter for coconut oil, same amount. The coconut flavor is subtle and actually pairs well with the chocolate. I have also used a dairy-free butter stick and could not tell the difference in the finished cake.

Can I pre-mix the dry ingredients ahead of time?

I do this all the time. I measure out the almond flour, cocoa powder, coconut flour, baking powder, sweetener, and salt into small zip bags. When I want one, I dump a bag into a mug, add the egg and melted butter, stir, and microwave. I keep three or four bags in the pantry so there is zero friction between me and chocolate.

What toppings work best?

My favorite is a teaspoon of peanut butter stirred in before microwaving. Readers tell me it really does taste like a peanut butter cup. After cooking, I sometimes add a spoonful of sugar-free whipped cream or a drizzle of melted sugar-free chocolate. For something with deeper chocolate flavor, try adding an extra teaspoon of cocoa powder.

Can I make keto chocolate mug cake in the microwave?

Yes, the microwave is exactly how I make this one. Mix everything in a 12 ounce or larger microwave safe mug and cook on high for 60 to 75 seconds. I check at 60 with a gentle shake and add 10 more seconds if the center wobbles. Total time is 2 minutes, and it comes in at 3.8g net carbs.

Can you make a 3-ingredient keto mug cake?

You can find stripped down versions, but I use 8 ingredients here on purpose. The coconut flour absorbs liquid and gives the cake body, and the baking powder gives it lift. Cut those and you lose the fudgy center. Every ingredient earns its spot, and the whole thing still takes 2 minutes at 3.8g net carbs.

What's the best flour substitute for keto mug cake?

Sunflower seed flour is my go-to swap for the 2 tablespoons of almond flour, used in the same amount. If coconut flour is all you have, cut the total to 2 to 3 teaspoons since it absorbs far more liquid. Either way the cake stays fudgy and lands at 3.8g net carbs.

Similar Recipes

Others looking for “The BEST EVER Keto Chocolate Mug Cake” also liked:

Low Carb Chocolate Mug Cake Recipe

a thick mug cake popping out of a mug with a dollop of whipped cream on top This low-carb chocolate mug cake is rich, fudgy, and absolutely not diet food. The texture is fluffy enough that even serious chocolate lovers won’t believe it’s sugar-free. And since it’s homemade, you know exactly what’s in it. The whole thing takes about two minutes from bowl to first bite. Top with fresh whipped cream for the full dessert experience. fluffy chocolate cake coming out of a white mug topped with whipped cream

What is a Mug Cake?

A mug cake is exactly what it sounds like: a cake you mix and cook right in a mug using the microwave. They’re single-serving desserts you can throw together in minutes when cravings hit.

Mug vs Ramekins for Making Mug Cakes

Most of the time I just use a regular coffee mug. But if you want a cuter presentation, you can use a ramekin too. Mix in the mug and transfer, or if your ramekin is big enough, use it for everything, mixing to serving. Either way, spray it with cooking spray first so the cake doesn’t stick. cutting out a bite of chocolate keto cake with whipped cream on top in a white ramekin

Portion Controlled Desserts

One of the things I love about mug cakes is the built-in portion control. You’re making one serving, so there’s no leftover cake tempting you from the counter. The benefits of portion control are not limited to maintaining a healthy weight, but also include:
  • Easy food digestion
  • Feel more energized throughout the day
  • Controlled blood sugar levels
  • No ingredients wasted
  • Less dirty dishes

How to Make a Sugar-Free Chocolate Mug Cake in the Microwave?

Making this in the microwave takes almost no effort.
  • Use a microwave-safe mug or a sufficiently-sized ramekin with cooking spray.
  • Mix all ingredients like almond and coconut flour, cocoa, and monk fruit sweetener in it.
  • Stir and add any extras you want (think flavor extracts like vanilla or coffee to boost the chocolate flavor).
  • Put the mug or ramekin in the microwave and give it around 60 seconds until batter appears to be all fluffy. Do not microwave for more than 75 seconds.
  • Let the cake cool for a minute and enjoy.
chocolate mug cake ingredients piled into a white coffee mug

Baking the Chocolate Mug Cake in the Oven

If you prefer the oven, here’s how:
  • Use a ramekin instead of a mug (your mug may not be oven safe)
  • Mix all ingredients in the ramekin
  • Stir to make a batter
  • Put the ramekin in the pre-heated oven at 350 degrees F for 12 to 14 minutes
  • Allow the cake to cool and enjoy

How to Make a Dairy-Free Chocolate Mug Cake

To make this dairy-free, replace the butter with coconut oil, same amount. Ghee is clarified butter, so it still comes from dairy and is not a true dairy-free swap. Coconut oil works great for low-carb baking, and the subtle coconut flavor pairs well with the chocolate.

Choosing Your Cocoa Powder

This recipe uses cocoa powder for all the chocolate flavor. Make sure you’re using 100% unsweetened cocoa powder, since some brands sneak in sugar and extra carbohydrates.

Can I Make a Larger Cake with this Recipe?

Yes! Just triple or quadruple the ingredients, pour them into a greased baking dish or cake pan, and bake at 325 degrees for 10-12 minutes.
About the Author
Annie Lampella, Pharm.D.

Annie Lampella, Pharm.D.

Annie is a Doctor of Pharmacy, mom, and the recipe creator behind KetoFocus. With a B.S. in Genetics from UC Davis, she has over 14 years of experience developing family-friendly keto recipes based on the science of human metabolism.

More Dessert Recipes

slice of keto carrot cake
45 Mins
Keto Carrot Cake
4.8 Stars (109 Ratings)

Moist, rich keto carrot cake with real shredded carrots and a tangy cream cheese frosting made with sour cream — 5.6g net carbs and 10.5g protein...

See the Recipe
keto chocolate chip cookie stack
55 Mins
Keto Almond Flour Chocolate Chip Cookies
4.7 Stars (53 Ratings)

The chewiest almond flour chocolate chip cookies I've ever baked — zero grainy texture and 3.2g net carbs for two cookies. I invented these keto...

See the Recipe
five golden brown chocolate chip cookies on the table with dark chips spread around
16 Mins
Best Keto Chocolate Chip Cookies
4.7 Stars (52 Ratings)

Crispy edges, chewy centers, close to Toll House — these keto chocolate chip cookies land at 1.2g net carbs each. The almond and coconut flour...

See the Recipe
creamy chocolate mousse in a small dish topped with sprinkles and strawberries
3 Mins
Keto Chocolate Mousse
4.7 Stars (31 Ratings)

Keto chocolate mousse from 3 ingredients — rich, airy, and just 3.1g net carbs. No cooking, no raw eggs, ready in under 5 minutes when the...

See the Recipe
pretty fluted edges on a pie crust
77 Mins
Keto Pie Crust
4.8 Stars (41 Ratings)

No one will guess this flaky, buttery keto pie crust is grain-free — just 1.5g net carbs. It's almond flour, coconut flour, cold butter, and one...

See the Recipe
chewy keto chocolate chip cookie with melted chips
3 Mins
Keto Chocolate Chip Cookie for One
4.6 Stars (49 Ratings)

One soft, chewy keto chocolate chip cookie, made in under 10 minutes with no eggs — just 2.5g net carbs. Bake it in the oven, the air fryer, or...

See the Recipe
Reviews 52
4.6
4.6 Stars (25 Ratings)
25 ratings · 28 written reviews
Made this recipe? Tap a star to rate it.
  1. A
    Andre Jul 14, 2026

    Came out fudgy and dense. I've made it three nights running.

    1. Annie Lampella
      Annie Lampella Jul 16, 2026

      Three nights running sounds about right for this one. Try allulose instead of monk fruit if you want it even fudgier, I've tested both and allulose holds more moisture, gets the texture closer to a brownie.

  2. T
    Travis Jul 4, 2026

    Probably made this a dozen times by now. Late-night sweet fix.

    1. Annie Lampella
      Annie Lampella Jul 10, 2026

      Two minutes at midnight is hard to beat. I stir a spoonful of peanut butter in before microwaving when I really want to go there. Comes out like a peanut butter cup.

  3. E
    Elaine Jun 26, 2026

    382 calories for a mug cake could go either way. Here it's the dark cocoa doing the work, and it delivers. First one I've had that doesn't taste like a negotiated settlement with a chocolate craving.

    1. Annie Lampella
      Annie Lampella Jun 30, 2026

      100% cacao is non-negotiable here. I tried Dutch process once and got that same almost-chocolate thing, close but not quite right.

  4. R
    Rhonda Jun 25, 2026

    Two flours instead of one, apparently.

  5. D
    Dina Jun 22, 2026

    9.9g protein and the collagen scoop blends right in.

  6. B
    Brittany Jun 8, 2026

    Any reason it uses both almond and coconut flour? Could you just double the almond flour if that's all you have?

    1. Annie Lampella
      Annie Lampella Jun 11, 2026

      The coconut flour soaks up liquid the almond flour can't. I tried just doubling the almond flour and the center came out too wet, didn't fully set. Stick with both.

  7. Y
    Yuki Jun 5, 2026

    I've never made anything keto before, and the only reason I tried this was because it was 95 degrees outside and there was no way I was turning on the oven. I scrolled past it three times before committing, because I genuinely could not imagine something with almond flour and coconut flour made in a mug tasting like real chocolate. The 75 seconds felt almost like a trick. But it rose, it set, and the texture was fudgy in a way that stopped me mid-bite. Not gummy, not dry -- the dark cocoa flavor is real and it hits. Four stars because I want to try it again without the pool chaos, but I'm already planning a second attempt. Can I add a spoonful of peanut butter without throwing off the texture?

    1. Annie Lampella
      Annie Lampella Jun 7, 2026

      Stir it in right before microwaving. A teaspoon is plenty. One of my readers, Brenda, does this every time and says it comes out like a peanut butter cup, which I cannot argue with.

  8. K
    Kimberley Morris Jun 1, 2026

    I added about 1/4 tsp vanilla, and 1 tsp sour cream, because it was too dry for me at only 45 seconds even with allulose. The additions made the cake nice and moist, but still not anything I'd call "fudgy". Next time I'll try 1 tbsp sour cream and see how that works for me. 😊

  9. K
    Kimberley Morris May 31, 2026

    Hm. Did mine for only 45 seconds, with allulose, and got no fudgy center. It still tastes good, though a little more on the dry side than I like. I live in Colorado Springs, and it's dry here, so that plus the altitude probably messed me up. Next time I will add a little vanilla extract for more liquid, and maybe even add a teaspoon of sour cream...? I know that can make cakes more moist.

  10. M
    Morgan May 26, 2026

    Made this last week when my son was hovering around the kitchen asking for dessert. He watched me throw everything in a mug and stick it in the microwave, pretty openly skeptical (he's sat through a few of my less successful keto attempts). Two minutes later he ate half of mine before I got more than a bite, then went looking for another mug. The fudgy center got him. He's twelve and doesn't care about net carbs, but apparently he cares about this.

    1. Annie Lampella
      Annie Lampella May 30, 2026

      A twelve-year-old who's sat through the keto fails going back for a second mug. That's the real test. The fudgy center gets everyone.

  11. K
    Kim Brown May 2, 2026

    I've started ending every weeknight with one of these and it's completely changed how I handle cravings. The two-minute cook time is the thing (I can make it before I even fully commit to wanting dessert and it's already done). I pre-measure the dry ingredients into little cups on Sundays so the weeknight version is basically just crack an egg and melt some butter. At 3.8g net carbs it fits no matter what the rest of my day looked like.

    1. Annie Lampella
      Annie Lampella May 4, 2026

      Pre-measuring on Sundays is exactly what I do. Dump a bag in, crack an egg, done. Two minutes is fast enough that you don't talk yourself out of it.

  12. S
    Sonia F. Apr 21, 2026

    There was this box mix mug cake I used to make in college, always at 10pm, always when my self-control had run out. I assumed that ritual was just gone when I went keto two years ago. Made this last Tuesday when a craving hit and I wasn't thinking straight, and when it came out at 70 seconds the smell stopped me cold. Barely-set center, that fudgy pull when the spoon goes in. I hadn't felt that in years.

    1. Annie Lampella
      Annie Lampella Apr 27, 2026

      That smell at 70 seconds is real. Took way too many test mugs to get the center right, but that fudgy pull is the whole point.

  13. J
    Jessica Garcia Apr 18, 2026

    My daughter is 9 and will eat anything chocolate. She wandered in right when mine came out of the microwave and I tried to tell her it was 'a grown-up thing with weird flour.' She took the fork anyway and ate half before I could say another word, then stood there looking at me like I had been hiding something from her. So now I make two mugs and let her think she's getting the exact same dessert as me. The monk fruit doesn't register to her at all. Only thing I'd mention is mine came out a little dry the first time because I went the full 75 seconds, so I pull it at 65 now and it's way fudgier.

    1. Annie Lampella
      Annie Lampella Apr 21, 2026

      She skipped past the 'grown-up thing' disclaimer and went straight to eating. Smart. And yeah, 65 is right for a hot microwave.

  14. A
    Amanda Apr 16, 2026

    Fudgy when you get the timing right (my microwave runs hot, 55 seconds worked better for me), but the monk fruit was a touch too sweet. First bite tasted more like sugar than cocoa. Four stars, tweaking the sweetener next time.

    1. Annie Lampella
      Annie Lampella Apr 18, 2026

      55 seconds is the call for a hot microwave. On the monk fruit, try cutting it to 2 teaspoons next time. The cocoa actually comes through a lot more when the sweetener isn't competing with it.

  15. N
    Nicole Apr 13, 2026

    First time making a mug cake and I went in expecting rubber. The texture is actually fudgy and 75 seconds is not a real amount of time to wait for chocolate. On my second one.

    1. Annie Lampella
      Annie Lampella Apr 18, 2026

      75 seconds is basically a tease. I stir a teaspoon of peanut butter in before microwaving. Tastes like a peanut butter cup.

Leave a Review

Rating

Get weekly keto recipes from Annie.

Join the list and get new recipes delivered to your inbox every week.