In a room of just 23 people there is a better than even chance that two share a birthday. Enter a group size to see the exact probability, the chance that someone shares your own birthday, and how many people you need to reach any target probability.
Last updated:
365 ignores 29 February; use 366 to include it, or any number for the general matching problem.
%
Shows how many people you need to reach this chance.
Enter your values to see the result.
Advertisement
Advertisement
How to use the Birthday Paradox Calculator
Enter the group size, for example 23 or the size of a class.
Keep 365 days or change it for leap years or other matching problems.
Optionally set a target probability to see how many people are needed.
Read the probability and compare it with the chance of matching your own birthday.
Explore the chart and table to see how fast the probability grows.
Birthday problem formula
For n people and d equally likely birthdays (d = 365):
It is the surprising fact that in a group of only 23 people the probability that at least two share a birthday is about 50.7%. It is not a true paradox, just counter-intuitive: 23 people form 253 pairs, and each pair is a chance for a match.
How is the probability calculated?
First find the chance that all birthdays are different: 365/365 × 364/365 × … × (365 − n + 1)/365. The chance of at least one shared birthday is 1 minus that product. For 23 people this gives 1 − 0.4927 = 0.5073.
How many people do you need for a 99% chance?
With 365 equally likely birthdays you need 57 people for a 99% chance and 70 people for about 99.9%. For a 50% chance you need 23 people, and with 366 or more people a shared birthday is certain (the pigeonhole principle).
Why is the chance of someone sharing MY birthday so much lower?
Matching a specific day is a much harder target. The chance that at least one of n − 1 other people has your birthday is 1 − (364/365)^(n−1). You would need 253 other people to reach 50%.
Are birthdays really equally likely?
Not exactly: real birth rates vary by season and day of the week, and 29 February is rarer. Uneven birthdays actually make a shared birthday slightly more likely, so the standard calculation is a slight underestimate.
Where else is the birthday problem used?
The same math explains hash collisions in computer science (the birthday attack), duplicate random IDs, and coincidences in lotteries. Change the number of days to model any situation where n items are spread randomly over d equally likely slots.
Are all the tools on FreeToolCabin tested for quality and accuracy?
Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.