Binomial Distribution Calculator

The binomial distribution counts successes in a fixed number of independent trials that each have the same chance of success, such as heads in 10 coin flips. This calculator finds the probability of exactly, at most, or at least k successes, and draws the whole distribution as a bar chart.

Try:

How to use the binomial distribution calculator

  1. Enter the number of trials n and the probability of success p.
  2. Enter the number of successes k and choose =, ≤ or ≥.
  3. Press Calculate to see the probability and the chart.

Formula

P(X=k)=(nk)pk(1−p)n−kP(X = k) = \binom{n}{k} p^k (1-p)^{n-k}

Worked example: 10 coin flips, exactly 6 heads

  • Number of trials n: 10
  • Probability of success p: 0.5
  • Number of successes k: 6
  • Find: P(X = k)

✓ Answer checked

P(X=6)≈0.20507813P(X = 6) \approx 0.20507813
As a percentage
20.5078%
Mean
np=5np = 5
Standard deviation
np(1−p)≈1.58114\sqrt{np(1-p)} \approx 1.58114
00.050.10.150.20: 0.000976562501: 0.0097656250000000112: 0.0439453125000000723: 0.1171875000000003534: 0.205078125000000645: 0.246093750000000956: 0.205078125000000667: 0.1171875000000003578: 0.0439453125000000789: 0.00976562500000001910: 0.000976562510
Probability of each number of successes; the highlighted bars make up P(X = 6).
Step-by-step working (2 steps)
  1. Binomial formula Binomial distribution

    Each outcome with exactly i successes has probability pⁱ(1 − p)ⁿ⁻ⁱ, and there are C(n, i) of them.

    P(X=i)=(10i)(12)i(1−12)10−iP(X = i) = \binom{10}{i} (\frac{1}{2})^{i} (1 - \frac{1}{2})^{10 - i}
  2. Substitute k

    Put i = 6.

    P(X=6)=(106)(12)6(0.5)4≈0.20507813P(X = 6) = \binom{10}{6} (\frac{1}{2})^{6} (0.5)^{4} \approx 0.20507813
Formulas used
P(X=k)=(nk)pk(1−p)n−kP(X = k) = \binom{n}{k} p^k (1-p)^{n-k}
How this was checked
  • ✓ All probabilities add up to 1, and P(event) + P(not event) = 1.

Probabilities rounded to 8 significant figures.

Frequently asked questions

What is the chance of exactly 6 heads in 10 flips?

C(10, 6) × 0.5¹⁰ = 210 ÷ 1024 ≈ 0.2051, or about 20.5%.

When can I use the binomial distribution?

When there is a fixed number of trials, each trial has two outcomes, the probability of success is the same each time, and the trials are independent.

What are the mean and standard deviation?

The mean is np and the standard deviation is √(np(1 − p)).

Related calculators

Related guides