Age facts

The Birthday Paradox: Why 23 People Are Enough for a Shared Birthday

Put 23 people in a room and the odds that two of them share a birthday are slightly better than a coin flip. The maths behind the birthday paradox, the formula, a table for groups up to 100, three-way matches and a check against real birth data.

The Birthday Paradox: Why 23 People Are Enough for a Shared Birthday

The birthday paradox says that in a group of just 23 people, the chance that at least two share a birthday is 50.7%. With 57 people it reaches 99%, and with 70 people it is 99.9%. That is far fewer than the 183 people it would take to fill half the calendar. The number is small because you are comparing every pair in the group, not just yourself against everyone else.

Why only 23 people?

The trick is in the number of pairs. In a group of 23, each person can be compared with 22 others. Counting every pair once gives 23 × 22 ÷ 2 = 253 pairs. Each pair has a small chance, 1 in 365, of matching. With 253 chances, a match becomes likely.

It is easier to work out the chance of no match at all, then subtract from 1:

  1. The first person can have any birthday: 365 out of 365.

  2. The second must avoid that day: 364 out of 365.

  3. The third must avoid two days: 363 out of 365.

  4. Keep going until the 23rd person, who must avoid 22 days: 343 out of 365.

  5. Multiply all those fractions together. For 23 people the result is 0.493, a 49.3% chance that everyone's birthday is different.

So the chance of at least one shared birthday is 1 − 0.493 = 0.507, or 50.7%.

The birthday paradox formula

Written out, the chance of at least one shared birthday among n people is:

P(n) = 1 − (365 × 364 × … × (365 − n + 1)) ÷ 365^n

There is also a handy shortcut. For a calendar of N equally likely days, you reach an even chance of a match at about 1.18 × √N people. For N = 365 that gives 1.18 × 19.1 ≈ 22.5, which rounds up to 23. The square root is the whole story: the number of pairs grows with the square of the group size, so the group only needs to be about the square root of the number of days.

Birthday paradox probability table

People in the group

Pairs to compare

Chance of a shared birthday

2

1

0.3%

5

10

2.7%

10

45

11.7%

15

105

25.3%

20

190

41.1%

23

253

50.7%

25

300

56.9%

30

435

70.6%

40

780

89.1%

50

1,225

97.0%

57

1,596

99.0%

70

2,415

99.9%

100

4,950

99.99997%

A school class of 30 has better than a 2 in 3 chance of a shared birthday. A wedding with 70 guests almost certainly has one.

Sharing your birthday is a different question

The paradox is about any two people matching. Finding someone who matches you is much harder, because now there is only one comparison per person.

Other people in the room

Chance someone shares your birthday

23

6.1%

100

24.0%

253

50.0%

365

63.3%

1,000

93.6%

You need 253 other people for an even chance that one of them has your birthday. Even with 365 others, the chance is only 63.3%, because some of them will share birthdays with each other instead.

What about three people with the same birthday?

A three-way match needs a much bigger group. We worked it out exactly for 365 equally likely days:

People in the group

Chance that three share a birthday

23

1.3%

50

12.6%

70

30.7%

88

51.1%

100

64.6%

The even-chance point is 88 people. So a group of 88 is more likely than not to contain three people with the same birthday, while 23 is enough for a pair.

Does it hold with real birthdays?

Real birthdays are not spread evenly. September is busy and holidays are quiet, as our post on the most common birthdays shows. Uneven birthdays make a match slightly more likely, not less.

We checked this with 21 years of US birth records (1994 to 2014). With the real share of births on each date, including February 29, a group of 23 has a 50.78% chance of a shared birthday. With equal days it is 50.73%. The difference is tiny. The classic answer of 23 holds.

A real example: at the 2014 FIFA World Cup, each squad had 23 players. Wikipedia notes that 16 of the 32 squads had at least one pair sharing a birthday, almost exactly the half the maths predicts.

Try it in a classroom or office

  1. Count the people in the room. With 30 or more, the odds favour a match.

  2. Go through the months in order and ask people to call out their birthday when their month comes up.

  3. Write each date on a board. The first repeat is your shared birthday.

With 23 people it works about half the time, so a single failed attempt does not disprove anything. With 40 people it works almost 9 times in 10.

The same maths in other places

The rule of about 1.18 × √N works for any set of equally likely options:

Options

Example

People (or items) for a 50% match

7

Day of the week you were born

4

12

Month you were born

5

24

Hour of the day you were born

7

365

Birthday

23

10,000

Random 4-digit PIN

119

1,000,000

Random 6-digit code

1,178

In computer security, the "birthday attack" uses the same idea to find two inputs that give the same hash, which is why hash outputs need to be long. Short random codes repeat much sooner than intuition suggests.

Who came up with the birthday problem?

The problem is usually credited to the British mathematician Harold Davenport, around 1927, though he did not publish it. Richard von Mises published a version in 1939. Mathematicians usually call it the birthday problem. "Paradox" is a popular name, because the answer is not a contradiction, only a surprise.

Want to see how far away your own birthday is? The Birthday Countdown shows the days, hours and minutes left, and the Days Between Dates calculator counts the gap between any two birthdays.

What is the birthday paradox?

It is the result that in a group of 23 people, there is a 50.7% chance at least two share a birthday.

How many people do you need for a 100% chance?

367. With 366 possible birthdays including February 29, 367 people guarantee a match. A 99.9% chance needs only 70.

Why is it called a paradox?

Because the answer feels wrong, not because it is a contradiction. Mathematicians usually call it the birthday problem.

What are the odds someone shares my birthday?

In a room of 23 other people, about 6.1%. You need 253 other people for a 50% chance.

How many people do you need for three to share a birthday?

88 people give a 51.1% chance of a three-way match, assuming 365 equally likely days.

Does the birthday paradox include leap years?

The classic version ignores February 29. Including it, and using real US birth data, changes the 23-person result from 50.73% to 50.78%.

What is the formula for the birthday problem?

P(n) = 1 − (365 × 364 × … × (365 − n + 1)) ÷ 365^n. A shortcut for an even chance is about 1.18 × √365, which is 23 people.

Who discovered the birthday problem?

It is usually credited to Harold Davenport around 1927. Richard von Mises published a version in 1939.

Sources

  • Birthday problem, Wikipedia (history, 253-person figure, 2014 World Cup squads)

  • US births 1994-2003 and 2000-2014, FiveThirtyEight data on GitHub (real-distribution check, calculated by Age Finder)

  • Probability tables, the three-way match and the collision table were calculated by Age Finder from the formulas above.

Age facts

The Most Common Birthdays and the Rarest Ones, Ranked

We ranked every birthday using 21 years of US birth records. September 9 comes first, Christmas Day comes last (after leap day), and the reasons are mostly about holidays and hospital schedules.

7 min read

Generations

The Silent Generation: Years, Ages and Why It Got That Name

The Silent Generation covers people born from 1928 to 1945. Here is how old they are now, why Time magazine called them silent in 1951, what they lived through and why the group is smaller than the ones around it.

6 min read

Generations

Gen Beta: Birth Years, Name and What We Know So Far

Every baby born from 1 January 2025 belongs to Generation Beta. Here are the birth years, the origin of the name, the projected size of the group, a milestone timeline and a year-by-year age table.

7 min read