Birthday Collisions

How many people must be in a room before two of them probably share a birthday? Far fewer than you think. The page computes the exact answer, then checks it by simulating thousands of rooms with a seeded random generator.

Exact chance of a shared birthday:
Simulated (0 rooms): –

Line: exact. Dots: simulated, 20,000 rooms per size once you run the big simulation. The dashed lines mark 50% and the first group size that passes it.

One random room (a day number 1–365 for each person; matches in orange)

How the exact number is found

The chance that nobody shares a birthday is 365/365 × 364/365 × … × (365−n+1)/365: each new person must avoid every day already taken. The chance of a shared birthday is one minus that. It passes one half at n = 23. The surprise comes from pairs: 23 people make 253 pairs, and each pair is a chance for a match.

Assumptions, stated plainly: 365 equally likely days, no 29 February, no twins, birthdays independent. Real birthdays are not quite uniform, which pushes the true chance slightly up, not down.