We've all seen it. A can of Coke is handled a little too much and explodes in a fountain of fizz when opened. What makes that happen? The common explanation is that soft drinks are carbonated, but it's actually a little more complicated than that. It's actually the result of a technique used to keep the fizzy drinks carbonated. Think about what happens every time you open a can of soda without shaking it first: You hear a familiar popping sound. That sound is the pressure inside the can being released. Soft drinks are canned under pressure to help keep them carbonated.
OK, but why does shaking the can change the amount of pressure? It doesn't. But when you shake a can, the carbon dioxide at the top of the can is spread throughout the liquid. Most of the air makes its way to the top of the can quickly, but some become bubbles that can stick to the sides and bottom of the can for a time. These bubbles can't escape when the can is opened, but the pressure is still there. The result? Instead of a pop of air escaping from the opened can, the pressure is relieved by the release of a burst of liquid, resulting in the sticky mess we've all experienced.
So how do you stop the explosion form happening? Try tapping the sides and bottom of the can. This works by giving the bubbles sticking to the can a nudge, sending them floating to the top of the can where they can be safely released as gas.