We develop a theory of political transitions inspired by the experiences of Western Europe and Latin America. Non-democratic societies are controlled by a rich elite. The initially disenfranchised poor can contest power by threatening revolution, especially when the opportunity cost is low, for example, during recessions. The threat of revolution may force the elite to democratize. Democracy may not consolidate because it is redistributive, and so gives the elite an incentive to mount a coup. Highly unequal societies are less likely to consolidate democracy, and may end up oscillating between regimes and suffer substantial fiscal volatility.