Every year from your current age to retirement, the balance grows by compound interest with a random annual return drawn from a normal distribution, plus your contribution:
B(t+1) = B(t) · (1 + r_t) + C, where r_t = μ + σ·Z_t, Z_t ~ N(0,1)
After retirement, contributions stop and a percentage-of-portfolio withdrawal is taken every year before the market return is applied:
B(t+1) = (B(t) − W(t)) · (1 + r_t), where W(t) = B(t) · w
If B(t) ever reaches zero the path is marked ruined for
every remaining year. Hundreds of independent paths are simulated with fresh
random draws of Z_t (Box–Muller transform); the risk of
ruin is the fraction of paths that ran out of money before the end of
the horizon, and the thick highlighted line is the median
balance across all paths in each year.
A 3D Monte Carlo simulation of compound growth and retirement withdrawals: hundreds of random market paths run at once, so you can see the spread of possible outcomes and the risk of running out of money — not just one lucky average.
Each year the balance grows by B(t+1) = B(t)·(1+r_t) + C before retirement, where r_t = μ + σ·Z_t is drawn from a normal distribution (Box–Muller). After retirement, a percentage withdrawal W(t) = B(t)·w is taken before that year's return is applied. A path that reaches zero is marked ruined; the risk of ruin is the share of paths ruined by the end of the horizon.
Drag the amber sphere to set the annual contribution, the orange ring to set the withdrawal rate, or the vertical marker to set the retirement age — or use the matching sliders. 🎲 Reroll draws a fresh batch of random paths for the same plan.
The classic "4% rule" comes from historical U.S. market studies suggesting a 4% initial withdrawal rate rarely exhausts a 30-year retirement portfolio — but it depends heavily on the sequence of returns you happen to get, which is exactly what this Monte Carlo cloud makes visible.