Share this link via
Or copy link
Bet The Flip (β)
Your current points are 10.
Current win streak: 2
Win streak bonus: x1.5
Which one will you bet on?
How much would you like to bet?
You're betting 3 points on heads.
If you're ready, please tap the button below, and flip your coin!
Result
You Win! You've earned points!
Current points: 10

This page is built for the probability classroom — but whether you're a teacher or just curious, you can watch probability happen instead of reading about it. Rather than studying the Law of Large Numbers or the binomial distribution in the abstract, you (or your students) can see them unfold in real time by running tens of thousands of virtual coin flips with a single click. Four interactive simulators below explore convergence, random walks, distributions, and streaks — the four ideas every introductory probability lesson must cover.
No installation, no spreadsheet — just open this page on any device and start exploring. Each simulator is self-contained, mobile-friendly, and works in both light and dark mode.
As you flip a coin more and more times, the observed proportion of heads should converge toward the true probability. Try it: type the number of flips, then run the simulation. Watch the line bounce wildly at first, then settle ever closer to the dashed reference line.
For discussion: Try 100 flips, then 10,000. How does the gap between observed and theoretical probability change? Now try a biased coin (p = 0.7). Does it still converge? You can also see this convergence on the site's actual data on the Site Statistics page.
The Law of Large Numbers says the proportion of heads will converge to 0.5. A common mistake is to assume the count of heads minus tails also converges to zero — but it doesn't. The gap actually drifts further from zero, just slowly enough that the proportion still settles. This kind of trajectory is called a random walk.
How big does the gap typically get? The typical gap is about 8 after 100 flips and about 80 after 10,000. The chart's grey envelope marks the wider 95% zone — the ±2σ band, where σ = √n for the heads-minus-tails count (about ±20 after 100 flips) — which a fair walk stays inside about 95% of the time. The proportion shrinks because the denominator grows faster than the gap — not because the gap itself shrinks.
For discussion: Run the walk a few times. Does it always return to zero? Why does the “gambler's fallacy” — the belief that a long streak of heads must be followed by tails to “balance out” — contradict what this graph shows? You can also see this concept applied to the site's live data on the Site Statistics page.
If you flip 100 coins and count the heads, you'll usually get something close to 50 — but rarely exactly 50. Repeat the experiment many times and the distribution of "heads counts" forms the familiar bell shape: the binomial distribution. The simulator runs many independent experiments at once and overlays the theoretical curve so students can see how empirical results approximate it.
For discussion: The theoretical mean of n flips is n·p, and the standard deviation is √(n·p·(1−p)). Compare these with the observed values. Why does the empirical mean almost match the theoretical, but the standard deviation can drift slightly?
Many students believe that a long run of heads — say, eight in a row — is evidence of bias. In fact, with 1,000 fair flips, the expected longest streak is around 9 (the log₂(n) − 1 rule of thumb). Long runs are a feature of randomness, not a bug. This simulator measures the longest streak in each of your experiments and shows the distribution.
The theoretical estimate uses the approximation E[Ln] ≈ log₂(n) − 1, valid for large n with a fair coin. The actual distribution is right-skewed because the longest streak can occasionally be much greater than the mean.
For discussion: If a student tells you a "lucky streak" of 7 heads proves a coin is biased, what does this simulator tell you? Run 5 experiments at n = 1000 — how often does the longest streak hit 12 or more?
Three lesson ideas you can build around this page:
This page supports the following common topics in introductory statistics:
Each simulator runs in your browser, so the math is fully transparent. Open your browser's developer tools and inspect the page source — students who want to learn programming can read the simulation code and modify it. The flips themselves use the browser's built-in crypto.getRandomValues() — the same cryptographically-strong randomness the live site uses for a single coin toss — so the numbers you see come from genuine high-quality randomness, not a toy generator.
Once your students have explored these four simulators, they can apply the same statistical tests to live data: the Site Statistics page runs a chi-squared test and Z-test on every coin flip ever performed on this site, with confidence intervals and a verdict on whether the coin is statistically fair. They can also see the same Law of Large Numbers and Random Walk visualizations applied to that real-world dataset.
Visit the main Flip a Coin page to generate fresh flips that contribute to the global experiment — turning abstract theory into something you can watch grow.