Draw Probability Calculator

StatisticsLast updated: August 22, 2026

When objects are drawn from a bag, a deck, or a production batch without being put back, every draw changes the odds of the next one. The binomial distribution no longer applies; the correct model is the hypergeometric distribution: with K of N objects being targets and n objects drawn, the probability of getting exactly k targets is P(X = k) = C(K,k)·C(N−K,n−k) / C(N,n).

Alongside the probability of exactly k, the tool reports at least k, at most k, none at all, and at least one; the expected value, variance, and standard deviation; a probability table covering the whole support; and a bar chart of the distribution. It also shows the binomial equivalent of the same calculation with replacement, so you can see how much difference the finite population correction makes.

The total number of balls in the bag, cards in the deck, or items in the batch.
How many of them are the kind you are looking for? For example, 4 aces in a 52-card deck.
How many objects are drawn without replacement.
How many of the drawn objects do you want to be targets? Exactly k, at least k, and at most k are computed together.

Hypergeometric Distribution Formulas

Exactly k targets: P(X = k) = [C(K, k) · C(N−K, n−k)] / C(N, n)
Support:           max(0, n+K−N) ≤ k ≤ min(n, K)
At most k:         P(X ≤ k) = Σᵢ₌₀ᵏ P(X = i)
At least k:        P(X ≥ k) = 1 − P(X ≤ k−1)
At least one:      P(X ≥ 1) = 1 − C(N−K, n) / C(N, n)
Expected value:    E(X) = n · K / N
Variance:          Var(X) = n · (K/N) · (1 − K/N) · (N−n)/(N−1)
Binomial version:  P(X = k) ≈ C(n, k) · pᵏ · (1−p)ⁿ⁻ᵏ,  p = K/N  (with replacement)

The formula is the share of draws containing exactly k targets among all C(N, n) possible draws. For large N the combinations grow too big to evaluate directly, so the tool works on a logarithmic scale; the result is the same and there is no overflow risk.

How to Calculate

  1. Enter the total number of objects (N): the cards in the deck, the balls in the bag, or the items in the batch.
  2. Enter how many of them are the kind you are after (K); for example, 4 aces in a 52-card deck.
  3. State how many objects you will draw (n); the objects are drawn without being put back.
  4. Enter how many of the drawn objects you want to be targets (k).
  5. Read the exactly k, at least k, and at most k probabilities together; for an "at least one" question, look at the P(X ≥ 1) row.
  6. Check where the peak of the distribution chart lies and how far your outcome sits from the expected value.

Worked Examples

Exactly one ace from a deck of cards

Drawing 5 cards from a 52-card deck, the probability of getting exactly 1 ace is [C(4,1)·C(48,4)] / C(52,5) = (4 × 194,580) / 2,598,960 = 29.95%. The probability of getting no ace is 65.88%, so the chance of seeing at least one ace is 34.12%. The expected number of aces is 5 × 4/52 = 0.3846.

Exactly 1 successes — P(X = 1): 29.95% · At least 1 successes — P(X ≥ 1): 34.12% · At most 1 successes — P(X ≤ 1): 95.83%

Matching three numbers in a 6/49 lottery

In a game where 6 of 49 numbers are drawn, the probability that exactly 3 of your 6 numbers match is [C(6,3)·C(43,3)] / C(49,6) = (20 × 12,341) / 13,983,816 = 0.017650, that is 1.77%. The probability of matching at least 3 is 1.86%, and the probability of matching all six is 1 in 13,983,816. The expected number of matches is 6 × 6/49 = 0.7347, and the chance of matching none is 43.60%.

Exactly 3 successes — P(X = 3): 1.77% · At least 3 successes — P(X ≥ 3): 1.86% · At most 3 successes — P(X ≤ 3): 99.90%

A clean batch in quality control

With 8 defective units in a batch of 100, the probability that a sample of 10 drawn without replacement contains no defective unit is C(92,10)/C(100,10) = 7,210,666,060,598 / 17,310,309,456,440 = 41.66%. In other words, the sample catches at least one defective unit only 58.34% of the time: this acceptance sampling plan misses roughly two out of five defective batches. The expected number of defective units is 10 × 8/100 = 0.8000, with a standard deviation of 0.8180.

Exactly 0 successes — P(X = 0): 41.66% · At least 0 successes — P(X ≥ 0): 100.00% · At most 0 successes — P(X ≤ 0): 41.66%

Frequently Asked Questions

What is the difference between the hypergeometric and the binomial distribution?
The binomial distribution is for draws with replacement: the probability of success stays constant on every trial and the trials are independent. The hypergeometric distribution is for draws without replacement; because the drawn object is not put back, the composition of what remains — and therefore the probability — changes at every step. When the sample is a small part of the population (n/N < 5%), the two distributions come very close.
How is the probability of 'at least one target' computed?
The practical route is through the complement: P(X ≥ 1) = 1 − P(X = 0), where P(X = 0) = C(N−K, n) / C(N, n). Adding up P(1) + P(2) + … gives the same answer but takes far longer. The tool shows both values on separate rows.
Why is the probability zero for some values of k?
Because the support of the hypergeometric distribution is bounded: the number of targets can be at least max(0, n+K−N) and at most min(n, K). With only 4 aces in a deck you cannot draw 5 aces in 5 cards; and if 8 of 10 objects are targets, 5 draws must contain at least 3 of them. For values outside that range the probability is exactly zero and the tool issues a warning.
What is the finite population correction?
It is the (N−n)/(N−1) factor in the variance formula. In a draw without replacement, uncertainty falls as the sample covers more of the population; in the limit, when n = N everything has been drawn and the variance goes to zero. The same factor is used to shrink the standard error in survey and audit sampling.
Can I compute lottery odds with this tool?
Yes. N is the total count of numbers, K the count of numbers on your ticket (or drawn), n the count drawn (or on your ticket), and k the number of matches you want. For 6/49, enter N = 49, K = 6, n = 6. The probability of matching every number comes to 1/C(49,6), that is 1 in 13,983,816.
Will I get the same result in Excel, SPSS, or R?
Yes. In Excel, HYPGEOM.DIST(k, n, K, N, FALSE) returns the same value, and setting the last argument to TRUE gives the cumulative probability. In R, use dhyper(k, K, N-K, n) and phyper(k, K, N-K, n). Take care not to mix the functions up, as the argument orders differ.
Does the calculation stay accurate for very large N?
Yes. Multiplying the combinations directly would overflow quickly, so for large parameters the tool works with the log-gamma function and exponentiates the result. In the step-by-step solution, combinations too large to print are left in symbolic form as C(N, n), but the probability is still computed exactly.