Prepare your mug by choosing one that’s microwave-safe and has at least a 12-ounce capacity to allow room for the cake to rise without overflowing.
Combine all dry ingredients directly in the mug – flour, sugar, cocoa powder, baking powder, and salt. Stir with a fork until thoroughly mixed and no cocoa clumps remain.
Add wet ingredients to the mug – milk, oil, coffee granules (or brewed coffee), and vanilla extract. Stir vigorously until you have a smooth batter with no dry patches.
Fold in chocolate chips if using, gently stirring them throughout the batter for pockets of melted chocolate in your finished cake.
Microwave on high power for 70-90 seconds. Start checking at the 70-second mark – the cake is done when it’s risen and the top looks set but still slightly moist. Be careful not to overcook!
Let stand for 2 minutes before eating. The cake will be extremely hot right out of the microwave, and this resting time allows it to finish cooking and develop the best texture.
Enjoy directly from the mug while still warm, optionally topped with a scoop of vanilla ice cream, whipped cream, or a dusting of powdered sugar.