Two levers, one foam
Aquafaba foam — the beaten liquid from cooked chickpeas — is not inherently stable. Left alone it begins to collapse within minutes: bubbles coalesce, liquid drains downward, and the whole structure sags. Acid and sugar address two different points of failure, and the distinction matters.
Cream of tartar, the usual acid, is potassium hydrogen tartrate. Added before or during whipping, it lowers the pH of the liquid toward the isoelectric range of the dissolved proteins. Counterintuitively, moving toward the isoelectric point here causes the protein chains to unfold more readily and pack more tightly at the air–water interface, forming a denser, more continuous film around each bubble. The net effect is faster foam formation and a tighter, more resilient peak. A small quantity — commonly around a quarter teaspoon per 120 ml of liquid — is enough; more does not improve the result.
Sugar works differently, and later. When beaten into an already-formed foam it dissolves into the thin water films between bubbles. This increases the viscosity of those films substantially, slowing the rate at which liquid drains away — a process called syneresis. Higher viscosity means the bubble walls thin more slowly, which in turn slows coalescence. Sugar also raises the boiling point of the water in the film, which matters when the foam is baked: the structure has longer to set before moisture escapes catastrophically. Fine caster sugar, dissolved gradually rather than added all at once, distributes most evenly.
The two effects compound each other. Acid stabilises the protein interface; sugar stabilises the water phase. Use only one and the foam is more fragile than it needs to be. The practical sequence follows from the chemistry: add the acid early, into the liquid before or at the start of whipping, so the proteins meet it as they unfold; fold or whisk the sugar in once soft peaks have formed, when there is enough structure to carry it without deflating the foam.
Get the order wrong and both additives are present but doing less work than they should.