How big does a room have to be
before two people share a birthday?

Make a guess before you scroll. Most people say you'd need hundreds. Fill a room below and see how often it actually happens.

Fill a room

Each person lands on their birthday. A blue square is one person. A pink square means two or more people landed on the same day.

—
shared birthdays in this room
70.6%
chance of at least one, for this room size

Why your guess was low

There are two different questions hiding inside "does anyone share a birthday?" — and your gut answers the wrong one.

On the left, you only compare yourself to everyone else. On the right, every pair gets compared, including all the pairs you're not part of. Every line is one chance at a match.

Compared to you only

4

Every pair compared

10

In a room of 30, that's 29 lines on the left and 435 on the right. Fifteen times as many chances. Each line is a long shot on its own, but 435 long shots add up.

Run it a thousand times

One room proves nothing. Run many rooms and watch how close the real result gets to the predicted one.

— of rooms had a match
70.6% predicted by the maths

The maths behind it

Counting every way a match can happen is hopeless — one pair, two pairs, three people on one day, and so on forever. So flip the question and count the one way it cannot: everybody gets a different day.

Line people up one at a time. Each new person has to dodge every birthday already taken.

Chance of no match: 0.294
So the chance of at least one match: 0.706

That last step — take the chance of the thing not happening and subtract it from 1 — is the complement rule. It turns an impossible count into a one-line calculation.

People in the roomChance of a shared birthday

Where this shows up at work

Two servers fail in the same week. Three customers turn out to share an address. A fraud alert flags accounts with matching details. The instinct is to assume a cause.

But in a database with thousands of records, there are enormous numbers of pairs — and coincidences happen on their own, with nobody causing them. Before you investigate, the complement rule tells you the baseline: how likely was this coincidence anyway? If the answer is "very," the coincidence is not evidence of anything.

This is the same arithmetic behind false-positive rates in fraud detection and duplicate-record matching. Different labels, identical maths.