Baking powder and baking soda. Both of them are used so frequently in quick baking projects that unless you are a recipe developer, rarely do you consider what each of them actually does for your finished product. How come my scones call for baking powder, but my buttermilk biscuits call for a mixture of powder and soda? Is there an easy way to substitute one for the other if I don't have both on hand? And why do I have to bake my muffins right after mixing the batter?
With traditional or "slow" breads, that leavening agent—the thing that creates bubbles that keep the bread light—is a living fungus called yeast. As the yeast consumes sugars present in the flour, it releases carbon dioxide gas, forming thousands of teeny tiny air pockets inside the dough and causing it to rise. Once you pop that dough in the oven, those air pockets heat up and further expand, and a phenomenon known as oven spring takes place. Finally, as the gluten gets hot enough, it sets into a semisolid form, giving structure to the bread, and turning it from wet and stretchy to dry and spongy.
The only problem with yeast? It takes a long, long time to work. Enter baking soda. Unrestricted by the protracted timeframes of biological organisms, it relies instead on the quick chemical reaction between an acid and a base.
Baking soda is sodium bicarbonate. It reacts with acids immediately upon contact to produce carbon dioxide. Carbon dioxide gets trapped within batters and expands upon baking, leavening your quickbreads. Because it reacts immediately, quickbreads made with baking soda must be cooked immediately after mixing. Because of its alkalinity, it can also hasten browning reactions, adding color (and thus flavor) to things like pancakes, cookies, and muffins.
Baking powder is sodium bicarbonate mixed with a powdered acid and a starch. It does not require an external acid in order to activate. Most baking powders are "double acting," meaning they produce carbon dioxide once upon coming in contact with moisture, then again after heating. Because of this, baking powder-leavened goods are generally lighter and fluffier than those that rely on baking soda alone. This doesn't mean that you can let a baking powder batter just sit around expecting the second batch of bubbles to do all the leavening for you—the initial reaction is vitally important to the texture of your baked goods.
Can I substitute one for the other?
With this knowledge, it should be clear that while it's possible to substitute baking powder in a recipe that calls for baking soda (use a ratio of three measures of baking powder for every measure of baking soda), you can't expect the flavor profile to remain the same with all the extra acid that baking powder adds to the mix.
On the other hand, it's quite simple to substitute baking powder with your own homemade mixture of baking soda, cornstarch, and cream of tartar (a powdered acid). For every teaspoon of baking powder, use 1/4 teaspoon of baking soda, 1/2 teaspoon of cream of tartar, and 1/4 teaspoon of cornstarch. But do bear in mind that your homemade mixture will not be double-acting, requiring you to be extra hasty to get your pancakes on the griddle or your zucchini bread in the pan immediately after mixing the batter.