Coin Toss Streak Calculator
Full Results
Context
* Expected longest run is an approximation using log₂(n) for a fair coin.
H = part of a streak H = heads, no streak T = tails
P(at least one streak) for a fair coin (p = 0.5), calculated by dynamic programming. Each cell shows the probability of seeing at least one run of that length within that many tosses.
| Streak length (k) | n = 10 tosses | n = 20 tosses | n = 50 tosses | n = 100 tosses | Specific sequence |
|---|
All values for heads streaks on a fair coin. Tails streaks have identical probabilities. Values rounded to 1 decimal place.
How the Coin Toss Streak Calculator Works
The calculator tracks the probability distribution across states representing how many consecutive matching outcomes have occurred so far. At each step, it updates these probabilities based on the next toss.
Formally, define a state as the length of the current unbroken run of the target outcome (from 0 up to k−1). Once the state reaches k, the desired streak has occurred. The calculator propagates these state probabilities across all n tosses and returns 1 minus the probability of never entering the success state.
This approach is exact. It does not enumerate all 2n sequences (which would be impossible for large n) and it does not use the common but incorrect approximation 1−(1/2)n.
Using the Calculator
This is the total length of your coin flip sequence. You can enter any value from 1 up to 10,000.
The calculator asks: how many consecutive matching outcomes in a row? If this exceeds the number of tosses, the probability is zero.
Select heads, tails, or either. The "either" option counts any run — heads or tails — that reaches the specified length.
A fair coin uses p = 0.5 for heads. A biased coin lets you enter any custom probability. The same dynamic programming method applies to both.
The result is P(at least one streak of the selected length occurs anywhere in the sequence). The complement shows the chance of seeing no such streak at all.
Coin Toss Streak Probability Formula
There are two fundamentally different probability questions. The first is simple. The second requires dynamic programming.
Specific sequence at a fixed position
For a fair coin, the probability that a specific consecutive sequence of k heads begins at a specified position is:
Fair coin, k heads
P = (1/2)^k
Biased coin, k heads
P = p^k
Fair coin, k tails
P = (1/2)^k
Biased coin, k tails
P = (1-p)^k
These formulas give the probability of an exact fixed-position sequence. They do not give the probability of a streak appearing somewhere within a longer sequence.
At least one streak anywhere in n tosses
This is the more useful question — and the one this calculator answers. There is no simple closed-form expression. The correct method tracks probability across consecutive-outcome states using the recurrence below.
Recurrence (heads streak, fair coin):
Let f(i, j) = probability of being in state j (i.e., j consecutive heads in a row ending at toss i) without having yet seen k consecutive heads.
f(0, 0) = 1 (start state)
For each toss i from 1 to n:
f(i, 0) += f(i−1, j) × 0.5 for each j in 0..k−1 (tails breaks the run)
f(i, j+1) += f(i−1, j) × 0.5 for each j in 0..k−2 (heads extends it)
P(at least one streak) = 1 − ∑ f(n, j) over j in 0..k−1
The same recurrence applies to biased coins by replacing 0.5 with p (for heads) and 1−p (for tails).
Worked Example: 3 Consecutive Heads in 5 Tosses
What is the probability of getting at least three consecutive heads somewhere within five fair coin tosses?
There are 25 = 32 equally likely sequences. Let's count which ones contain at least one run of 3 heads.
| Sequences with at least one HHH | Notes |
|---|---|
| H H H T T | HHH at positions 1–3 |
| H H H T H | HHH at positions 1–3 |
| H H H H T | HHH+ at positions 1–4 |
| H H H H H | Five-head run, contains HHH |
| T H H H T | HHH at positions 2–4 |
| T H H H H | HHH+ at positions 2–5 |
| H T H H H | HHH at positions 3–5 |
| T T H H H | HHH at positions 3–5 |
Eight sequences out of 32 contain at least one run of three consecutive heads, giving a probability of 8/32 = 25%.
Why not just multiply? A naive calculation might suggest P = (n−k+1) × (1/2)k = 3 × 1/8 = 3/8 = 37.5%. This overcounts because sequences where HHH starts at position 1 and again at position 2 would be counted twice. The correct answer, 25%, requires either exhaustive enumeration (for small n) or dynamic programming (for any n).
Specific Sequence vs. Streak Anywhere
This distinction is worth repeating clearly because it causes more confusion than almost any other concept in streak probability.
Question 1: Specific sequence
"What is the probability that the next 5 tosses produce HHHHH?" This is a fixed, ordered question. There are 25 = 32 possible sequences of 5 tosses and only one of them is HHHHH. So the answer is 1/32 ≈ 3.1%.
Question 2: Streak anywhere in 100 tosses
"What is the probability of seeing at least five consecutive heads somewhere in the next 100 tosses?" Now the streak can start at toss 1, toss 2, … or toss 96. The events overlap and interact. In 100 fair tosses, the probability of at least one 5-head streak is approximately 81%. These two numbers — 3.1% and 81% — describe entirely different events.
Exactly k vs. at least k
A streak of at least k means the run reaches length k or longer and still qualifies. A streak of exactly k means the run has precisely k matching outcomes with different outcomes on either side (or at the boundary). The calculator uses "at least k," which is the standard interpretation and the more useful measure for most purposes.
Common Coin Toss Streak Questions
What is the probability of 3 heads in a row?
For a specific three-toss sequence: (1/2)3 = 12.5%. For at least one 3-head streak within a longer sequence:
| Total tosses | P(at least one 3-head streak) |
|---|---|
| 5 | 25.0% |
| 10 | 50.7% |
| 20 | 75.6% |
| 50 | 97.0% |
| 100 | 99.9% |
What is the probability of 5 heads in a row?
For a specific five-toss sequence: (1/2)5 = 3.125%. For at least one 5-head streak:
| Total tosses | P(at least one 5-head streak) |
|---|---|
| 5 | 3.1% |
| 10 | 6.3% |
| 20 | 12.5% |
| 50 | 28.1% |
| 100 | 49.9% |
What is the probability of 10 heads in a row?
For a specific ten-toss sequence: (1/2)10 = 1/1024 ≈ 0.098%. For at least one 10-head streak in 100 tosses, the probability is approximately 1.0%. In 1,000 tosses, it rises to about 9.4%.
What are the odds of a long streak in 100 flips?
| Streak length | P(at least one heads streak in 100 tosses) |
|---|---|
| 3 consecutive | 99.9% |
| 5 consecutive | 49.9% |
| 6 consecutive | 26.2% |
| 7 consecutive | 13.4% |
| 8 consecutive | 6.8% |
| 10 consecutive | 1.0% |
Does a Coin Streak Make the Opposite Outcome More Likely?
No. A fair coin has no memory. After five consecutive heads, the probability of heads on the next toss is still exactly 50%. The coin does not know what happened before.
The belief that tails is "due" after a string of heads is called the gambler's fallacy. It is one of the most common and persistent errors in probability reasoning. The sequence HHHHHT and the sequence HHHHHH are equally likely for a fair coin.
Why do so many people fall for it? Human pattern recognition is calibrated to detect meaning in sequences. A run of five heads looks like it "should" end. But the coin's physics are identical on every toss. Each flip is an independent Bernoulli trial, and prior outcomes have no causal path to future ones.
What about runs in sports or financial markets?
When evaluating claimed "hot streaks" in basketball shooting or investment performance, the right question is whether the observed streak rates exceed what independent random processes would produce anyway. Random sequences produce surprisingly long runs. A player making 10 consecutive shots does not by itself constitute evidence of a genuine hot-hand effect without controlling for how many streaks a random process of the same length would generate.
Why Random Events Produce Streaks
People tend to expect random sequences to alternate neatly between outcomes, roughly like: H T H T H T. But truly random sequences do not look like that. Consider this example from 12 fair coin tosses:
This sequence — H T H H T T T H H H H T — contains a 3-tail run and a 4-head run. It also has 6 heads and 6 tails (50/50), so it is consistent with a fair coin. Random processes naturally produce clusters.
This happens because at every step, the coin doesn't "know" what came before and doesn't aim to balance the sequence. The probability of extending a run of j identical outcomes is the same as the probability of starting any individual outcome: p for heads, (1−p) for tails. Streaks are not anomalies in random data. They are a predictable feature.
Streaks and the law of large numbers
The law of large numbers tells us that over a very long sequence, the proportion of heads approaches the true probability p. But the law says nothing about short-run balance. Over 10 tosses, getting 7 or 8 heads is common. Insisting that short sequences must stay near 5 heads out of 10 misapplies the law. Streaks fit naturally within a long sequence even while the overall proportion converges to 50%.
Fair Coin vs. Biased Coin Streaks
The streak calculator supports both fair coins (p = 0.5) and biased coins with any custom probability.
| Feature | Fair coin | Biased coin |
|---|---|---|
| P(heads) | 50% | User-defined |
| P(tails) | 50% | 1 − p |
| Heads vs tails streak likelihood | Symmetric | Asymmetric |
| P(5 heads in a row, specific sequence) | (0.5)5 = 3.1% | p5 |
| Longest expected head run | ≈ log2(n) | ≈ log1/p(n) |
| Calculator mode | Default (50%) | Select "Biased coin" |
With p = 0.7 (70% heads probability), a 5-head streak in 20 tosses becomes much more likely than with a fair coin. The recurrence calculation adjusts automatically for the custom probability value.
What Is the Expected Longest Coin Toss Streak?
For a fair coin, the expected length of the longest run of heads in n tosses is approximately log2(n). For n = 100, this gives roughly log2(100) ≈ 6.6, meaning you would typically expect a longest heads run of around 6 or 7 in 100 flips.
The expected longest run of either heads or tails in n tosses is approximately log2(n) − 1. There is a classical result that the distribution of the longest run is concentrated around this value.
| Total tosses (n) | Expected longest heads run | Expected longest run (either) |
|---|---|---|
| 10 | ≈ 3.3 | ≈ 2.3 |
| 50 | ≈ 5.6 | ≈ 4.6 |
| 100 | ≈ 6.6 | ≈ 5.6 |
| 500 | ≈ 9.0 | ≈ 8.0 |
| 1,000 | ≈ 10.0 | ≈ 9.0 |
| 10,000 | ≈ 13.3 | ≈ 12.3 |
These are approximations. The simulation tab in the calculator lets you run repeated experiments and observe the distribution of actual longest runs.
Practical Streak Probability Examples
Example 1: 10 flips, streak of 3
In 10 fair coin flips, the probability of seeing at least 3 consecutive heads somewhere in the sequence is 50.7%. Most people find this higher than expected. Streaks of 3 in 10 flips are not rare events — they happen about half the time.
Example 2: 20 flips, streak of 5
In 20 fair coin flips, the probability of at least 5 consecutive heads is approximately 12.5%. The probability of at least 5 consecutive heads or tails (either) is roughly 23%, since both qualifying events count.
Example 3: 50 flips, 6 consecutive tails
In 50 fair coin flips, the probability of at least one 6-tail streak is approximately 14.5%. That is higher than many people intuitively expect for a run six long.
Example 4: 100 flips, 7 consecutive heads
In 100 fair coin flips, the probability of at least one 7-head streak is approximately 13.4%. Even a run of 7 is not unusual in a sequence this long.
Example 5: Biased coin, 60% heads
With a coin biased 60% toward heads (p = 0.6), the probability of a 5-head streak in 20 tosses rises to approximately 25%, compared to 12.5% for a fair coin. The bias amplifies head-streak probability and suppresses tail-streak probability symmetrically.
A coin toss streak is a sequence of consecutive identical outcomes. Three heads in a row (H H H) is a 3-head streak. Four tails in a row (T T T T) is a 4-tail streak. The outcomes must be back-to-back. A streak breaks whenever the result changes.
For a streak at a fixed position, raise the probability to the streak length: pk for heads, (1−p)k for tails. For the probability of at least one streak anywhere in n tosses, the correct method is a dynamic programming recurrence that tracks consecutive-outcome states across each flip. This calculator does that automatically.
For a specific fixed-position sequence: (1/2)3 = 12.5%. For at least one 3-head streak anywhere in 10 fair tosses: approximately 50.7%. The second number is higher because there are multiple positions where the streak could start.
For a specific five-toss sequence on a fair coin: (1/2)5 = 3.125%. For at least one 5-head streak in 20 tosses: approximately 12.5%. In 100 tosses, this rises to roughly 50%.
For a specific fixed-position sequence on a fair coin: (1/2)10 ≈ 0.098%. For at least one 10-head streak in 100 tosses: approximately 1.0%. In 1,000 tosses, this rises to about 9.4%.
No. A fair coin has no memory. After any number of consecutive heads, the next toss remains 50% heads and 50% tails. The belief that the other side is "due" is the gambler's fallacy, a well-documented error in probability reasoning that has no basis in how independent coin tosses work.
Theoretically, there is no upper limit. A streak of any length is possible. In n tosses, the probability of a streak of length n (all heads or all tails) is (1/2)n, which is small but not zero. Very long sequences are overwhelmingly likely to contain shorter streaks.
In 100 fair coin flips, the probability of at least one run of 5 consecutive heads is roughly 50%. A run of 6 consecutive heads has about a 26% chance, and 7 consecutive heads about 13%. Long streaks are far more common than intuition suggests, because there are so many positions in a 100-flip sequence where a streak could start.
Yes. For a fair coin, the probability of k consecutive heads and k consecutive tails are identical at any given position and within any n-toss sequence. The coin's symmetry makes the streak probabilities identical for both sides.
A specific sequence asks: what are the odds these particular k tosses in this order all come up heads? The answer is (1/2)k. A streak anywhere asks: what are the odds that at least one run of k heads appears at some point in the next n tosses? The second probability is always greater than or equal to the first, and grows with n. These are different questions with different answers.
A coin biased toward heads makes heads streaks more common and tails streaks less common. With p = 0.6, a 5-head streak in 20 tosses occurs with roughly twice the probability compared to a fair coin. Use the "Biased coin" setting and enter your custom probability to calculate the exact result.
The gambler's fallacy is the mistaken belief that independent random outcomes influence each other. After five consecutive heads, many people feel the next toss "should" be tails. In reality, each toss is independent. The coin has no memory, and the probability of heads remains 50% regardless of prior results.
No. You can calculate the probability that a streak will occur in a given number of tosses, but you cannot predict when it will happen or which specific tosses will form it. Probability gives you the long-run frequency, not the specific outcome of any individual toss.
The calculator uses dynamic programming. It tracks the probability of being in each possible "consecutive outcome" state at each toss, from 0 consecutive matching results up to k−1. Once the state reaches k, the streak has occurred. After n tosses, the probability of never reaching that state is the complement of the streak probability. This method is exact and avoids enumerating all 2n sequences.
Related Pages on Statistics Fundamentals
This calculator belongs to the probability and randomness section of the site. Related tools and learning pages:
Summary
Coin toss streaks are normal features of random sequences, not signs of bias or pattern. The probability of seeing a streak depends on how long the sequence is, how long the streak is, and what side you are counting — but never on what happened in previous tosses.
The most important distinction is between a specific sequence probability — (1/2)k for a fixed position — and the probability of at least one streak appearing anywhere in n tosses, which requires the dynamic programming calculation this tool performs.
Try different combinations in the calculator: increase the number of tosses and watch the probability climb. Switch to a biased coin and see how asymmetry changes the streak odds for each side. Run the simulation multiple times to observe how much longest-streak results vary even when the probability stays constant.