Is Flipping a Coin Truly Random? The Math and Physics Behind 50/50

Is Flipping a Coin Truly Random? The Math and Physics Behind 50/50
Is Flipping a Coin Truly Random? The Math and Physics Behind 50/50

Photo by Tezos on Unsplash

When you tap the coin on Flip a Coin.com, do you really get a fair 50/50 chance of Heads or Tails? The short answer is yes — and the longer answer reveals interesting science about randomness, probability, and why a digital flip can actually be more fair than a physical one.

How Online Coin Flips Generate a Result

Flip a Coin.com uses the browser's built-in window.crypto.getRandomValues() — a cryptographic-quality random source — to draw a 32-bit integer for each flip; whether that integer is even or odd decides Heads or Tails — an exact 50/50 split of the 232 possible values. (Multi-flip runs and API calls are generated on the server with PHP’s random_bytes(), also a cryptographic source.) Each flip is independent, meaning previous results never influence the next one.

Why Cryptographic Randomness Is More Than Fair Enough

The Web Crypto API draws from your operating system's cryptographically secure random source — the same machinery your device uses to create encryption keys and secure connections. These sources blend hardware entropy with vetted algorithms designed to defeat both statistical analysis and prediction, which is a far higher bar than a fair coin flip needs.

(For the technically curious: that means Windows CNG, Apple's system CSPRNG, or /dev/urandom on Linux — sources built to resist not just statistical analysis but cryptographic adversaries, a far higher bar than a fair coin flip needs.)

Physical Coin Flips Aren't Perfectly 50/50

Real-world coin flips have measurable biases:

  • Thumb-flicked flips: a 2007 physics model by Persi Diaconis and colleagues predicted a roughly 51% bias toward landing on the same side the coin started. In 2023, Bartoš et al. put it to the test with 350,757 real flips by 48 people — and found that coins landed on their starting side 50.8% of the time (95% interval 50.6% to 50.9%), in line with the prediction, though the size of the effect varied from person to person and shrank with practice. The same data showed no heads-or-tails bias: 175,421 of the 350,757 flips came up heads (50.0%).
  • Spun coins: weight distribution skews results far more. A US penny spun on its edge can land tails up as often as 80% of the time, an effect of the coin’s rim and edge geometry that appears when spinning — a different mechanism from an airborne flip.

The Bartoš paper also prints its results coin by coin. Heads and tails stayed balanced whichever coin was used:

CoinFlipsHeadsShare of heads [95% interval]
0.50 EUR57,44528,6170.498 [0.494, 0.502]
2 EUR48,77224,2760.498 [0.493, 0.502]
1 EUR37,82918,9200.500 [0.495, 0.505]
0.20 EUR31,37315,6650.499 [0.494, 0.505]
5 SEK15,9028,0520.506 [0.499, 0.514]
1 SGD15,4007,6550.497 [0.489, 0.505]
All 44 coins combined350,757175,4210.500 [0.498, 0.502]

Source: Bartoš et al., arXiv 2310.04153, version 4, Table 2 (CC BY 4.0). The six coins with the most flips, labelled as printed in the paper.

A digital flip has neither a thumb nor a heavy side — which is why it can be more fair than the real thing.

Verifying Fairness With Large Samples

Flip a Coin.com counts every flip performed on the site (tracking began in January 2024). Across more than 250 million flips and counting, the heads/tails distribution converges to the expected 50/50 within a few hundredths of a percentage point — you can check the live numbers anytime on the Site Statistics page, which runs formal fairness tests on the full dataset.

When You Need True Randomness

For everyday decisions, games, and fun, this site's flip is more than random enough — as explained above, it already draws from a cryptographically secure source. The distinction only matters at the extremes: regulated gambling systems and security-key generation use dedicated, audited hardware randomness with formal certification. For everything else — what to eat, who pays the bill, who goes first — a browser flip backed by your operating system's cryptography is as fair as chance gets.

Try it now: Flip a coin and see the result for yourself. The randomness is real.

References

  • Diaconis, P., Holmes, S., & Montgomery, R. (2007). "Dynamical Bias in the Coin Toss." SIAM Review, 49(2), 211–235. epubs.siam.org — physics model predicting ~51% same-side bias for a thumb-flicked coin.
  • Bartoš, F. et al. (2023). "Fair coins tend to land on the same side they started: Evidence from 350,757 flips." arXiv preprint 2310.04153. arxiv.org/abs/2310.04153 (version 1 October 2023; version 4 April 2025) — 178,079 of 350,757 flips landed on the starting side (50.8%); 175,421 came up heads (50.0%).
  • Gelman, A. & Nolan, D. (2002). "You Can Load a Die, But You Can't Bias a Coin." The American Statistician, 56(4), 308–311. tandfonline.com — source of the spun-penny tails bias figure.
  • Murray, D. B. & Teare, S. W. (1993). "Probability of a tossed coin landing on edge." Physical Review E, 48(4), 2547. link.aps.org — ~1 in 6,000 edge-landing estimate for a US nickel.
  • Web Crypto API — MDN Web Docs. developer.mozilla.org — specification of crypto.getRandomValues().

Frequently Asked Questions

Is a real-world physical coin flip exactly 50/50?
Not quite. A 2007 physics model by Persi Diaconis and colleagues predicted that physical coin flips have a slight bias (~51%) toward landing on the same side they started, because a flipped coin wobbles slightly in flight and so spends a little more time with its starting side up. A 2023 experiment with 350,757 flips measured 50.8% — while heads and tails themselves came out even (50.0% heads).
How does an online coin flip work?
Modern online flippers, including this site, use the browser's built-in crypto.getRandomValues() from the Web Crypto API — drawing from operating-system cryptographic random sources. For statistical fairness over many flips this is indistinguishable from true randomness, and across more than 250 million flips on this site (and counting), the heads/tails split sits within fractions of a percentage point of 50/50.
What's the difference between true and pseudo-random?
True random numbers come from physical processes (atmospheric noise, radioactive decay). Pseudo-random numbers come from deterministic algorithms with seed values. For coin flipping, both produce fair 50/50 distributions over enough trials.
Can a coin land on its edge?
Rarely, but yes. Physicists Daniel Murray and Scott Teare estimated that a US nickel flipped onto a hard surface lands on its edge about 1 in 6,000 flips. On softer surfaces or with thicker coins, the chance is higher.

Share this link via

Or copy link