Birthday Paradox Calculator - Coincidence odds made clear

Use this birthday paradox calculator to show the chance that two people in a group share a birthday, plus the smallest group that reaches your target probability.

Updated: July 8, 2026 • Free Tool

Birthday Paradox Calculator

Choose whether to compute the match probability from a group size, or the group size needed to reach a target probability.

How many people are in the room. Used when calculating probability from group size.

The chance of a shared birthday you want to reach. Used when solving for group size.

Number of equally likely days. Use 365 for birthdays, or another value for non-birthday matching problems.

Results

Probability of a shared birthday
0%
Probability all birthdays are distinct 0%
Group size needed 0people
Possible days 0days

What Is Birthday Paradox Calculator?

A birthday paradox calculator works out the chance that at least two people in a group were born on the same day of the year. Despite the name, this is not a true paradox but a counterintuitive result from probability: a room of just 23 people has a better-than-even chance of containing a shared birthday, while most people guess the number would need to be far larger. The calculator does the counting for you and reports the answer as a percentage you can compare against your own intuition.

You reach for this calculator whenever you need a quick, trustworthy answer about coincidences in a group. Teachers use it to open a probability lesson, party planners use it to settle bets about guest birthdays, and security engineers use the same math to reason about hash collisions. The birthday paradox calculator turns the fuzzy question "how likely is that?" into a precise figure you can defend, instead of a rough guess that usually lands far too low.

If you want the baseline single-event machinery behind these numbers, the probability calculator covers the general rules for working out the chance of one event happening. This page builds on that idea by stacking many pairwise comparisons on top of each other.

How Birthday Paradox Calculator Works

P(shared) = 1 − (365! / ((365 − n)! × 365n)) = 1 − ∏k=1n−1 (1 − k/365)
  • n: number of people in the group
  • 365: equally likely days in a standard year
  • P(shared): probability at least one matching pair exists

Worked example: 23 people

  1. The first person can have any birthday, so the distinct-birthday factor starts at 1.
  2. The second person must differ from the first: 364/365.
  3. This continues as 363/365, 362/365, and so on, down to (365 − 22)/365 for the 23rd person.
  4. Multiplying all 22 fractions gives about 0.4927, the chance that every birthday is different.
  5. Subtracting from 1 gives 0.5073, so the shared-birthday probability is about 50.73 percent.

The 50.7 percent result for 23 people is documented in the encyclopedic treatment of the birthday problem, which uses the same complement formula. The product form is what this site actually computes, because it stays accurate for large groups where the factorial expression overflows.

The formula works by reversing the question. Counting every possible matching pair directly is messy, so the calculator instead counts the chance that no two birthdays match, then subtracts that from 1. Each new person multiplies in another "different from everyone so far" fraction, and the running product is the probability that all birthdays stay unique.

Probability theory models the likelihood of events such as shared birthdays by counting favorable outcomes against all equally likely outcomes, as surveyed in Britannica's overview of probability theory. Intuitive guesses about coincidence often miss the real figure because people think about one birthday against 365 days rather than about the many pairs a group creates.

Key Concepts Explained

Complement rule

Instead of counting every possible matching pair directly, the calculator reports the probability that no birthdays match and subtracts it from 1. This single subtraction is what makes the whole problem tractable, because the "all different" path involves one clean chain of multiplications while the "at least one match" path would mean adding up dozens of separate cases.

Pairwise comparisons

A group of n people contains n(n-1)/2 distinct pairs. With 23 people that is 253 pairs, which is why a match becomes likely far sooner than the 183 "half the year" intuition suggests. The comparison is between every two people, not between one person and the calendar, and the number of those comparisons grows quickly.

Equally likely days

The formula assumes each of the 365 days is equally probable. Real birth distributions cluster around certain months, so the real-world chance of a match is usually slightly higher than the model predicts. The equal-day version is the standard teaching baseline and the one most references quote.

Pigeonhole principle

Once the group size reaches or exceeds the number of days, a shared birthday follows from logic rather than from probability. With 366 or more people in a 365-day year, there are more people than calendar days, so at least two must share a date. The calculator reports a probability of 100 percent in that region rather than a value just below it.

The number of distinct birthday pairs grows with group size, a counting idea you can explore with the combination calculator. Another puzzle where intuition breaks down is the door game explained by the Monty Hall problem calculator. Intuitive judgments about coincidence often diverge from the formal multiplication rule that underlies the birthday paradox, a gap discussed in the Stanford Encyclopedia of Philosophy's treatment of probability. Both puzzles reward working from the rule rather than from a first guess.

How to Use This Calculator

  1. 1 Step 1: Pick a calculation mode: probability from a group size, or the group size needed to reach a target probability.
  2. 2 Step 2: Enter the group size (number of people) when working out a probability, or the target probability when solving for a group size.
  3. 3 Step 3: Keep the possible days at 365 for birthdays, or change it for a different matching problem such as 52 weeks or 12 months.
  4. 4 Step 4: Read the shared-birthday percentage and the complement percentage shown beside it.
  5. 5 Step 5: Use the group-size mode to answer questions like "how many people give a 90 percent chance of a match?"
  6. 6 Step 6: Check the distinct-days output to confirm the assumption your result is built on.

To work out the group size for a 90 percent match, set the mode to group size, enter 0.9 as the target, and leave days at 365. The calculator returns 41 people. The same steps work for any target, so you can ask "how many people give a 99 percent chance?" and read 57 straight from the result. Unlike a coin toss where each flip is independent, the birthday match builds on comparisons between people, a contrast the coin flip probability calculator makes concrete by keeping every trial separate.

Benefits of Using This Calculator

  • Benefit: Get an exact coincidence percentage in seconds instead of trusting a guess that is usually far too low, which matters when you are settling a bet or planning a lesson.
  • Benefit: Show the complement probability side by side so students can see why the result feels wrong and where the number actually comes from.
  • Benefit: Switch to group-size mode to plan events, classrooms, or experiments around a chosen confidence level rather than around a vague hunch.
  • Benefit: Reuse the same math for non-birthday matching by changing the number of possible days, so the tool is not limited to calendar dates.
  • Benefit: Replace hand multiplication of dozens of fractions with one reliable computation that never drops a term or rounds too early.

If you want to model repeated independent trials instead of pairwise matches, the binomial distribution calculator covers the underlying distribution, while the statistics calculator handles means, variance, and sampling around these coincidences. The two tools complement this one when you move from "will any pair match?" to "how often does this pattern repeat?"

Factors That Affect Your Results

Group size

The dominant factor. Probability climbs steeply with each added person because the number of possible pairs grows quadratically, so going from 23 to 30 people moves the match chance from about 51 percent to about 71 percent.

Number of possible days

Fewer days means matches appear much faster. Setting days to 12 for months gives a 50 percent match with only 4 people, and setting it to 7 for weekdays needs just 4 as well, because the pool of slots shrinks while the number of comparisons stays the same.

Uneven birth distributions

Because real birthdays are not perfectly uniform, actual match rates are typically a little higher than the equal-day model shows. Hospitals report more births on some weekdays than others, which nudges the real probability upward by a small but real amount.

  • The model assumes every day is equally likely, which is only an approximation of real human birth data and will rarely be exact for a specific population.
  • It ignores leap-day births and treats February 29 the same as any other date unless you adjust the day count, so results for 366-day years are approximations.

These limits do not change the headline lesson. The match rate still rises far faster than most people expect, and adjusting the day count is enough to model related problems such as shared birth months or survey collisions.

Birthday paradox calculator showing the probability of a shared birthday for a group of people with the standard 365-day assumption
Birthday paradox calculator showing the probability of a shared birthday for a group of people with the standard 365-day assumption

Frequently Asked Questions

Q: What is the birthday paradox?

A: The birthday paradox is the observation that in a group of only 23 people there is about a 50.7 percent chance that two of them share a birthday. It is called a paradox because the number feels far too small, but it follows directly from counting the many possible pairs in the group.

Q: How many people need to be in a room for a 50 percent chance of a shared birthday?

A: Twenty-three people give roughly a 50.7 percent chance of at least one shared birthday under the equal-365-day assumption. The calculator confirms this and shows the exact complement of about 49.3 percent.

Q: Why does the birthday paradox feel wrong?

A: Most people compare one birthday against 365 days and expect to need about 183 people. The calculator works from pairs instead: 23 people form 253 pairs, so the chance that none of those pairs match falls below half surprisingly quickly.

Q: Does the birthday paradox account for leap years?

A: The standard calculation uses 365 equally likely days and ignores February 29. You can set the possible-days field to 366 for a closer model, though the result changes only slightly because leap-day births are rare.

Q: What is the exact birthday paradox formula?

A: The formula is P(shared) = 1 - (365! / ((365 - n)! * 365^n)), which equals 1 minus the product of (1 - k/365) for k from 1 to n-1. This site computes that product directly so it stays accurate for large groups.

Q: Can the birthday paradox be applied to other matching problems?

A: Yes. By changing the number of possible days you can model any 'collision' question, such as shared birth months (12 days), or the chance that two random items land in the same bucket in a hash table. The calculator's adjustable day count supports these cases.