The Binomial Distribution Calculator works out the probability of an exact number of successes. Enter trials, probability, and successes to get the result.

Binomial Distribution Calculator

Exact and cumulative binomial probabilities together — P(X = k), P(X ≤ k), P(X ≥ k), mean, variance and SD in one run.

Free to use Both cumulative tails Log-space: n up to 1000 Save PDF · PNG · Share

Enter your values

Fill in the fields below — the result appears with every step shown.

Shown on the printed, PDF and PNG copies of your result. Leave blank to stay anonymous.

Enter a valid value for number of trials n.

Enter a valid value for successes k.

Enter a valid value for probability of success p (0 to 1).

As a decimal: 0.5 for a fair coin.

Local browser calculation

Review your inputs and the tool’s supported scope before using the result.

Calculator loading… If this message stays, this view is not running the calculator's script — open this file in a full browser tab, then press Calculate.

Your result will appear here

Enter your values above, then press Calculate — or press Enter in any field.
TinyExe Binomial Distribution Calculator tinyexe.comFree online calculators

TinyExe · Binomial Distribution Result

Calculated locally in your browser

Calculated on
—

–
—

Name

—

Number of trials n

—

Successes k

—

Probability of success p (0 to 1)

—

How this was calculated

    What to do next

      TinyExe · tinyexe.com — Runs 100% in your browser — your numbers never leave this tab; nothing is uploaded or stored.

      TinyExe PDF & PNG exports carry the TinyExe logo and tinyexe.com header & footer.

      Runs 100% in your browser — your numbers never leave this tab; nothing is uploaded or stored.

      Embed this tool

      Add this Binomial Distribution Calculator to your own page — copy the code below and paste it where you want the tool to appear.

      The embed loads the live calculator in a frame, so it stays up to date automatically. Choose a width, check the code, then copy it. When you publish on WordPress, keep the src pointing at your live tool URL.

      Works in WordPress (Custom HTML block), HTML pages, and most site builders.

      The short answer

      A binomial distribution calculator evaluates P of X equals k as C of n k times p to the k times one minus p to the n minus k. For exactly three heads in ten fair flips that gives zero point one one seven one eight eight, with cumulative tails, mean, variance and standard deviation alongside.

      • P(X = k) = C(n,k) p^k (1-p)^(n-k)
      • Mean = np ; Variance = np(1-p) ; SD = sqrt(np(1-p))
      • Cumulative P(X <= k) answers 'at most' questions

      Binomial checkpoints (n = 10, p = 0.5; mean 5, variance 2.5, SD 1.5811)

      Reference values for this calculator.

      kP(X = k)P(X <= k)
      00.0009770.000977
      30.1171880.171875
      50.2460940.623047
      70.1171880.945313
      100.0009771.000000

      The formula

      The exact formula this calculator uses — every variable in it is explained in the card below.

      The formula

      P(X = k) = C(n, k) p^k (1 - p)^(n - k) ; also P(X <= k), P(X >= k), mean np, variance np(1-p) and SD sqrt(np(1-p)) ; value = P(X = k)

      Ideas enhancement: matches and extends the live tool's distribution output — exact probability plus both cumulative tails, mean, variance and standard deviation — computed in log-space so large n (up to 1000) does not overflow.

      Worked examples

      Worked examples with the full working shown — try them in the calculator to check.

      Example 1

      Coin flips

      n = 10, k = 3, p = 0.5

      CalculationSteps
      C(10, 3) = 120. P = 120 x 0.5^3 x 0.5^7 = 120 / 1024 = 0.117188. Cumulative P(X <= 3) = 0.171875. Mean = 10 x 0.5 = 5, variance = 10 x 0.5 x 0.5 = 2.5, SD = sqrt(2.5) = 1.5811.P(X = 3) = 0.117188 (11.72%).

      Result

      Example 2

      Guessing a quiz

      n = 20, k = 10, p = 0.25

      CalculationSteps
      C(20, 10) = 184,756. P = 184,756 x 0.25^10 x 0.75^10, which the calculator evaluates to 0.009922. Cumulative P(X <= 10) = 0.996058. Mean = 20 x 0.25 = 5, variance = 20 x 0.25 x 0.75 = 3.75, SD = sqrt(3.75) = 1.9365.P(X = 10) = 0.009922 — under 1%: pure guessing rarely reaches half marks.

      Result

      Example 3

      Certainty edge case

      n = 5, k = 5, p = 1

      CalculationSteps
      With p = 1 every trial succeeds: P(X = 5) = 1 exactly and all other outcomes are 0. Mean = 5 x 1 = 5, variance = 5 x 1 x 0 = 0, SD = 0.P(X = 5) = 1 — the boundary case handled exactly, not approximately.

      Result

      How to use this calculator

      Step 1

      Enter the number of independent trials n.

      Step 2

      Enter the exact number of successes k you are asking about.

      Step 3

      Enter the success probability p as a decimal between 0 and 1.

      Step 4

      Read P(X = k) as the headline and the cumulative probabilities, mean, variance and standard deviation in the details.

      Step 5

      Use P(X = k) for 'at least' questions.

      In short: The binomial distribution gives the probability of each possible number of successes in a fixed number of independent two-outcome trials.

      Frequently asked questions

      When is a distribution binomial?

      When there are a fixed number of independent trials, each with two outcomes and the same success probability: fixed n, independence, two outcomes, constant p.

      What is the difference between P(X = k) and P(X <= k)?

      Exactly k versus at most k. 'At least' and 'at most' questions — the common exam phrasing — need the cumulative values, which the details card provides.

      Why is P(X = 5) for 10 fair flips only about 0.246?

      Because the probability spreads over 11 possible outcomes (0 to 10). The single most likely outcome still holds under a quarter of the total probability.

      What are the mean, variance and standard deviation?

      Mean = np (the expected number of successes), variance = np(1 - p) (the standard deviation squared) and SD = sqrt(np(1 - p)). For 10 fair flips: mean 5, variance 2.5, SD 1.5811.

      How large can n be?

      Up to 1,000 here — probabilities are computed in log-space (summing log factorials terms) so factorials never overflow, unlike naive implementations.

      About this calculator

      A binomial distribution calculator computes the probability of each outcome of a binomial experiment — a fixed number of independent trials with constant success probability — returning the exact probability P(X = k), the cumulative probabilities P(X <= k) and P(X >= k), and the distribution's mean, variance and standard deviation.

      The formula assembles three pieces: choose which trials succeed (C(n, k) ways), the probability of those k successes (p^k), and the probability of the remaining failures ((1 - p)^(n - k)). Multiplying them counts every arrangement of the same outcome once — which is why exactly-5-heads is more likely than exactly-10: there are 252 arrangements of the former and only 1 of the latter.

      Cumulative questions dominate real use ('at most 2 defects', 'at least 8 passes'), and they are answered by summing the exact probabilities — the details here always include both tails so the at-least figure does not require a subtraction the user must remember to do. Mean np, variance np(1-p) and SD sqrt(np(1-p)) complete the picture by locating and scaling the distribution the probabilities describe.

      Use it for probability coursework, for quality and A/B-test reasoning (how likely is this many conversions by chance?), and for any repeated yes/no process: coin flips, defective items, survey responses, free throws.

      How to calculate it yourself

      Step 1

      Verify the setting is binomial: fixed n, independent trials, two outcomes, constant p.

      Step 2

      Compute the binomial coefficient C(n, k).

      Step 3

      Multiply by p^k and by (1 - p)^(n - k) for P(X = k).

      Step 4

      For cumulative questions, sum P(X = i) over the required range of i.

      Step 5

      Report alongside the mean np, variance np(1 - p) and standard deviation sqrt(np(1 - p)) for context.

      Real-life examples

      Student checking a 'passing by guessing' fear

      A student facing 20 four-option questions needs 10 to pass and worries pure guessing could do it.

      P(X = 10) at p = 0.25 is 0.009922, and even P(X >= 10) is only 0.013864 (about 1.39%) by the cumulative line. The distribution has mean 5, variance 3.75 and SD 1.9365, so 10 successes sits well into the upper tail.

      Guessing is not a strategy — she revises, with the number that proves why.

      Quality manager's defect question

      A line produces 3% defectives; an inspector samples 10 items and asks the chance of exactly none being defective versus the tool's k = 3 default view.

      Setting k = 0, p = 0.03: P(X = 0) = 0.97^10, about 0.737. Exactly 3 defects would be far rarer (the calculator's P(X = 3) at these settings is about 0.0025).

      Zero defects in a sample is the normal expectation (about 74%), so one defect found is information, not yet an alarm.

      Ideas & use cases

      • Shape exploration: fix n = 10 and run p = 0.1, 0.5, 0.9 at the mean k to feel how the distribution slides and skews.
      • At-least practice: read P(X >= k) directly for threshold questions instead of subtracting from 1 — then verify once by hand that they agree.
      • Normal-approximation preview: compare P(X <= k) here with a z-score estimate using the shown mean, variance and SD to see when the approximation earns its keep.

      Limitations & sources

      • Single binomial setting (one n, one p) per run with n up to 1000; it does not draw the full distribution chart or handle Poisson/geometric distributions.

      Sources: Binomial distribution definition and formulas: standard statistics references (OpenStax Introductory Statistics, binomial chapter)

      Binomial Distribution Calculator · TinyExe calculator suite Free to use · No sign-up · Instant results