ThisCalculator

Date and time

Birthday Paradox Calculator: Match Probability

Updated · Standard formula, shown below

Chance of at least one shared birthday Cannot compute %
Chance all birthdays are different
Cannot compute %
Result
Number of people
23 people
You entered

Birthday Paradox Calculator: Match Probability

A birthday paradox calculator estimates the chance that at least two people in a group share a birthday, assuming birthdays are independent and equally likely across 365 days. Enter the group size to get the probability of a match and the probability that everyone has a different birthday.

Formula

For a group of n people and 365 equally likely birthdays, the probability of at least one shared birthday is:

P(match) = 1 − P(all different) = 1 − [365 × 364 × 363 × … × (365 − n + 1)] / 365n.

Here, n is the number of people (a count, with no physical unit). The numerator counts the possible assignments in which each person has a different birthday; the denominator counts all possible birthday assignments. The calculator reports both probabilities as percentages. Its second result is the complement: the chance that all birthdays are different.

The equivalent compact expression for the different-birthday probability is 365! / [(365 − n)! × 365n]. The calculator’s factorial expression is intended for group sizes from 0 through 365. A group larger than 365 must contain a shared birthday under this model, by the pigeonhole principle; use 100% for the match probability in that case.

Worked Example

Using the default input of 23 people:

  1. For the first person, any of the 365 birthdays is allowed. For the second to avoid a match, 364 days remain; for the third, 363 remain, continuing until 343 days remain for the 23rd person.
  2. P(all different) = (365 × 364 × … × 343) / 36523 ≈ 0.4927.
  3. P(match) = 1 − 0.4927 ≈ 0.5073.

Rounded to the calculator’s two decimal places, the chance of at least one shared birthday is 50.73%; the chance everyone has a different birthday is 49.27%.

Why 23 People Is Enough

The result often surprises people because they picture one particular person and ask whether someone else shares that person’s birthday. But the calculator asks whether any pair shares a birthday. With 23 people there are 23 × 22 / 2 = 253 distinct pairs to compare. Each new person can match any of the birthdays already in the group, so the number of opportunities for a match grows rapidly.

That is the birthday paradox: it is not a contradiction or a trick in the arithmetic. It is an example of how pair counts grow faster than group size. The probability reaches 50% at 23 people in the standard 365-day model. This does not mean a 23-person group is guaranteed to include a match; it means that across many comparable groups, about half would be expected to have one or more matching pairs.

How to Use and Read the Result

Enter the number of people in the group. The headline result is the percentage chance that at least two people share a birthday. The second output gives the complementary chance that no birthdays match. For example, a match probability of 50.73% means a little more than half under the model, not that a specific person has a 50.73% chance of matching a chosen individual.

  • Use the number of people whose birthdays are being compared, not the number of possible pairs.
  • For a match between two specified people, the probability is 1/365, or about 0.27%, under the same assumptions.
  • For 50 people, the chance of at least one match is about 97.04% under the standard model.
  • At 366 people, a shared birthday is certain if birthdays fall on only 365 possible days and every person has one birthday in that calendar.

Assumptions and Limits

The standard calculation treats every day of a 365-day year as equally likely and assumes each person’s birthday is independent of everyone else’s. Real birthday distributions are not perfectly uniform: birth rates vary by date and place, and leap-day birthdays add another possible date. Consequently, a real group’s probability can differ somewhat from the calculator’s estimate.

The model also treats birthdays as calendar dates, not birth years or exact times. It does not ask whether people were born in the same year, nor does it account for twins or other relationships that can make birthdays dependent. If the group has a known birthday distribution, a more tailored probability calculation can use that distribution instead of assuming equal chances. The standard answer is a useful baseline, not a prediction about every particular group.

Common Misunderstandings

A frequent mistake is to confuse “someone shares my birthday” with “some two people share a birthday.” For one named person compared with 22 others, the chance that at least one of those 22 shares that person’s birthday is 1 − (364/365)22, about 5.9%. The 50.7% result considers every possible pair among all 23 people, including pairs that do not involve the named person.

Another mistake is to add individual pair probabilities as if the pair events were all independent. They are not: different pairs may involve the same person and birthday. The product formula for everyone having different birthdays avoids that error by counting sequentially how many unused dates remain.

Frequently Asked Questions

How many people are needed for a 50% chance of a shared birthday?
In the standard 365-day model, 23 people give a probability of about 50.73%. With 22 people, the probability is about 47.57%.

What is the birthday paradox formula?
Calculate the chance that all birthdays are different as (365/365) × (364/365) × … × ((365 − n + 1)/365), then subtract that value from 1. The result is the chance of at least one match.

Does the birthday calculator include leap years?
No. This calculator uses 365 equally likely birthday dates and omits February 29. A model with 366 equally likely dates can be calculated by replacing 365 with 366 throughout, but actual birthday frequencies are not exactly uniform.

What if I want to know whether someone shares my birthday?
That is a different question from whether any pair in the group matches. If 22 other people are compared with one specified person, the standard-model chance of at least one match with that person is about 5.9%, not 50.7%.

Can a group have more than a 100% chance of a match?
No. Probability cannot exceed 100%. Under a model with exactly 365 possible dates, any group of 366 or more people must contain at least one shared date.

Related

Formula used
in n | Number of people | people | 23 | 0
out match | Chance of at least one shared birthday | % | 100 * (1 - fact(365) / (fact(365 - n) * 365 ^ n)) | 2
out unique | Chance all birthdays are different | % | 100 * fact(365) / (fact(365 - n) * 365 ^ n) | 2

Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.