The shared-birthday odds that pass 50% with just 23 people.
How many people must gather before two of them share a birthday? With 365 possible days, it feels like you'd need a crowd. Run the experiment and your mind will change.
The birthday problem is not about you — it is about pairs.
Experiment
Hands-on experiment
Chance of a shared birthday (any two people)
Still under one half. Push the slider up.
🎲 Classroom simulation
Draw random birthdays for this many people and see if any really collide.
📖 Read more — why it exists · insights · common mistakes · formulasExpand ▾
Why
Why does this exist?
Probability is where intuition fails most often. The birthday problem shows that gap at its most dramatic: the answer you feel and the answer you compute are wildly different.
Counting collisions doesn't stop at birthdays. Passwords, ID numbers, and cryptography all hinge on 'what are the odds two random values coincide?' — a core question of modern security.
When a probability is hard to count head-on, count the opposite. 'At least one pair' is messy; 'no pairs at all' is one clean chain of multiplications. That complement trick is this lab's second gift.
Insight
Insights from the video
“Your eyes count people; probability counts pairs.”
Twenty-three people look like few, but pairing them up gives 253 pairs. Collision chances ride on the pair count, not the head count. Step out of the protagonist's seat and the probability appears.
“When 'at least one' is hard, count 'none at all'.”
Matching cases come in too many flavors to enumerate. The opposite — everyone different — is a single line of multiplication. Subtract from 1 and you're done. The complement is probability's shortcut.
Misconception
Common misconceptions
365 birthdays, so you'd need about 183 people for a 50% chance.
That intuition computes 'someone matching ME'. The question asks about 'any two people'. There are n people but n(n−1)/2 pairs, so the opportunities are far more numerous.
A match in a small group must be coincidence or a trick.
Repeat the simulation and matches appear about half the time at that group size. It isn't a spooky coincidence — it's the natural consequence of how many pairs there are.
Formula
Writing it as math
The formula only summarizes the experiment. Instead of counting matches head-on, compute 'everyone different' as a chain of multiplications and subtract from 1. The slider you moved becomes the letter n.
The complement
As each person enters, multiply the chance they differ from everyone before. Subtract the product from 1 to get the chance of a match.
Counting pairs
The number of two-person pairs among n people. With 23 people: 253 pairs. Collision chances grow with this number.
The √N estimate
With N possible values, about 1.2√N random picks give a 50% collision chance. N = 365 gives about 23. Security engineers use this exact estimate for hash collisions.
In Real Life
Where you meet it in real life
Hash collisions and security
Computers summarize files and passwords into hashes. However many values exist, about √N attempts yield a 50% collision — a calculation cryptographers call the 'birthday attack'.
Duplicate ID numbers
Randomly assigned IDs, student numbers, and coupon codes collide sooner than expected. Designers of numbering systems compute this probability first.
Lottery numbers repeating
Winning combinations number in the millions, yet as draws accumulate, the chance of a repeat combination grows fast. Several national lotteries have made headlines with repeated winning numbers.
The illusion of coincidence
'Two classmates share a birthday', 'two strangers share a name' — amazing at first, common once you count pairs. You gain an eye for fact-checking the news's 'incredible coincidences'.
Practice
Practice — conquer the types
✏️ 4 practice problems — solve to conquerTap to solve ▾
In a class of 50, how likely is a shared birthday?
What is the real reason 23 people are enough to pass one half?
How many two-person pairs do 10 people form?
For a 50% chance that someone shares YOUR birthday, about how many people are needed?
Watch
Related video
Connection
Concepts connect
Previous concept
Probability
The sense that long repetition reveals a ratio underlies this whole simulation.
← Probability labLeads to next
The Monty Hall Problem
The next door where probability betrays intuition — this time with three doors and goats.
Go to the The Monty Hall Problem lab →Related
Labs worth exploring together
Related lab
Related lab
Exponents
Even a number near 1 shrinks fast when multiplied many times — the feel of a multiplication chain.
Go to the Exponents lab →