Coin Flip Simulator Calculator
Use our free Coin flip simulator Calculator for quick, accurate results. Get personalized estimates with clear explanations.
Reviewed by Daniel Agrici, Founder & Lead Developer
Formula
P(k heads in N flips) = C(N,k) x p^k x (1-p)^(N-k)
Where C(N,k) is the binomial coefficient (N choose k), p is the probability of heads per flip, k is the number of heads, and N is the total number of flips. The expected number of heads is N x p, and the standard deviation is sqrt(N x p x (1-p)).
Worked Examples
Example 1: Fair Coin 100 Flips
Problem:Simulate 100 flips of a fair coin (50% heads probability). What results are expected?
Solution:Expected heads: 100 x 0.50 = 50\nStandard deviation: sqrt(100 x 0.5 x 0.5) = 5\nNormal range (95%): 50 +/- 10 = 40 to 60 heads\nExpected longest streak: log2(100) = ~6-7 flips\nChi-square threshold for fairness: < 3.84\nA typical result might show 47 heads and 53 tails
Result:Expected: ~50 heads | Normal range: 40-60 | Typical longest streak: 6-7
Example 2: Biased Coin Detection
Problem:A coin suspected of bias shows 60% heads. After 200 flips with 120 heads, is it biased?
Solution:Expected heads (fair): 200 x 0.50 = 100\nStandard deviation: sqrt(200 x 0.5 x 0.5) = 7.07\nObserved: 120 heads\nZ-score: (120 - 100) / 7.07 = 2.83\nChi-square: (120-100)^2/100 + (80-100)^2/100 = 8.0\nChi-square > 3.84, so reject fairness at 95% confidence
Result:Z-score: 2.83 (> 2) | Chi-square: 8.0 (> 3.84) | Likely biased coin
Frequently Asked Questions
Is a coin flip truly random and what makes it fair?
A physical coin flip is considered effectively random for practical purposes, though it is technically deterministic because the outcome is governed by the laws of physics including the force applied, angle of launch, air resistance, and landing surface. Research by Stanford professor Persi Diaconis found that a coin flipped with a mechanical flipper starts heads-up and lands heads-up about 51% of the time, showing a very slight bias toward the starting position. For most real-world purposes, this 1% bias is negligible and coin flips are treated as fair 50/50 events. Digital coin flip simulators use pseudo-random number generators that produce results indistinguishable from true randomness for statistical purposes.
What is the law of large numbers and how does it apply to coin flips?
The law of large numbers states that as the number of trials increases, the observed proportion of outcomes will converge toward the expected probability. For a fair coin, this means the percentage of heads will approach 50% as you flip more and more times, though the absolute difference between heads and tails counts can actually increase. After 10 flips you might see 60% heads, but after 10,000 flips the percentage will likely be between 49% and 51%. This convergence is not because the coin corrects itself or because tails become more likely after a run of heads, which would be the gambler's fallacy. Each flip remains an independent event with a 50% probability regardless of previous outcomes.
How is the chi-square test used to determine if a coin is fair?
The chi-square test compares observed results to expected results to determine whether any deviation from the expected 50/50 split is statistically significant or just due to random chance. The test statistic is calculated by summing the squared differences between observed and expected counts divided by the expected counts for both heads and tails outcomes. A chi-square value less than 3.84 (with 1 degree of freedom) means the coin's behavior is consistent with being fair at the 95% confidence level. Values above 3.84 suggest the coin may be biased, and values above 6.63 provide strong evidence of bias at the 99% confidence level. This test requires a reasonably large sample size of at least 50 to 100 flips to be meaningful.
How many coin flips do I need to determine if a coin is biased?
Detecting a biased coin requires a substantial number of flips, and the smaller the bias the more flips you need. To detect a coin biased 55/45 with 95% confidence, you need approximately 400 to 500 flips. For a more subtle 52/48 bias, you would need roughly 2,500 to 3,000 flips. A coin biased 60/40 can typically be detected with just 100 to 150 flips. The mathematical basis for these sample size requirements comes from statistical power analysis using the binomial distribution. In practice, physical coins may have biases of 1 to 2 percent that would require tens of thousands of flips to conclusively detect, making them effectively fair for all practical purposes.
References
Reviewed by Daniel Agrici, Founder & Lead Developer ยท Editorial policy