What causes hiccups?
An involuntary spasm of the diaphragm, followed a fraction of a second later by the vocal cords snapping shut. The spasm draws air in sharply; the closing cords stop it abruptly, and that abrupt stop makes the sound.
The reflex arc involves the phrenic and vagus nerves and a control centre in the brainstem. Once triggered it repeats rhythmically, typically four to sixty times a minute.
Common triggers are mostly things that irritate or distend the nerves' territory: eating too quickly, large meals, fizzy drinks, alcohol, swallowing air, sudden temperature changes, and excitement or stress.
Why the reflex exists at all is unclear, and the most interesting proposal is evolutionary. The hiccup pattern — sharp inspiration followed by immediate glottal closure — closely resembles the movement amphibians use to pump water across their gills while keeping it out of the lungs. Human foetuses hiccup frequently, well before birth, and one hypothesis is that the reflex is a retained remnant of that ancestral circuitry. Another suggests it helps infants clear air from the stomach while suckling.
The folk remedies mostly work, when they work, by raising carbon dioxide or stimulating the vagus nerve: holding your breath, breathing into a paper bag, drinking cold water quickly, swallowing granulated sugar, or pulling on the tongue. Evidence for each is largely anecdotal, and expectation probably plays a part.
Most bouts stop within minutes.
Hiccups lasting more than 48 hours are called persistent and can indicate an underlying medical problem — that is worth seeing a doctor about rather than treating with remedies.