Normal approximation calculator
For 100 trials with a 0.5 chance of success, the normal approximation puts the chance of exactly 50 successes at about 8%, using a mean of 50, a standard deviation of 5 and the continuity correction. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Trials
- 100
- Power (W)
- 0.5
- Successes
- 50
- Tail
- Eq
- Mean
- 50
- Variance
- 25
- Stddev
- 5
When a binomial experiment has many independent trials, the exact probability of a given number of successes becomes expensive to write by hand and awkward to look up in a printed table. The classical workaround is the normal approximation to the binomial: replace X ~ Binomial(n, p) with a normal curve that shares the same mean np and the same variance np(1-p), then read the area under that curve. This calculator takes a positive integer trial count, a success probability strictly between zero and one, and a target success count, applies the Yates continuity correction that turns a discrete count into a half-unit interval, and returns the approximate probability together with the mean, standard deviation, and the two continuity-corrected z scores.
How the normal approximation to the binomial is defined
A binomial random variable X counts the number of successes in n independent Bernoulli trials that each have the same success probability p. Its exact mean is n times p and its exact variance is n times p times one minus p. The de Moivre–Laplace theorem, a special case of the central limit theorem, says that as n grows the standardized count (X minus the mean) over the standard deviation converges in distribution to a standard normal Z.
Practically, that means you may treat X as approximately normal with mean mu equals n p and standard deviation sigma equals the square root of n p (1-p), and then convert any event about X into an area under that bell curve. Because X is discrete and the normal is continuous, a raw point probability P(X equals k) would collapse to a single line of zero area.
The Yates continuity correction repairs that mismatch by spreading the integer k across the unit interval from k minus one half to k plus one half, so P(X equals k) is read as the normal area between those two half-integers. The same half-unit shift turns a left tail P(X at most k) into the area to the left of k plus one half, and a right tail P(X at least k) into the area to the right of k minus one half.
Where this calculator earns its keep, and how it is priced
Quality and reliability teams use the same shortcut when n is large enough that an exact binomial sum is inconvenient and they only need a planning-grade tail probability for defect counts, pass-fail inspections, or go-no-go sampling plans. Product and growth analysts approximate conversion-count probabilities when a campaign is modeled as n independent Bernoulli trials with a historical success rate p and they want the chance of hitting or missing a target k.
Keep requests inside the published trial ceiling, pin the rounded probability in tests, and you get a reproducible normal approximation without standing up a statistics package. If you later need the exact binomial mass or cumulative, land on the exact binomial probability calculator instead; if you already have two z bounds and only want the area between them, use the standard normal interval tool. Those are different search intents and different landings, not overloads of this normal-approximation page.
What you can do with it
Homework and exam approximation drills
Students and graders check P(X=k), P(X≤k), or P(X≥k) under the Yates-corrected normal approximation for given n, p, and k.
Inspection and defect-count planning
Quality teams approximate the chance that a large binomial inspection lot hits a defect or pass target without summing an exact mass.
Campaign and conversion target odds
Analysts treat n independent conversions as binomial and approximate the probability of reaching a target success count k.
FAQ
How does the normal approximation to the binomial work?
X ~ Binomial(n, p) is treated as Y ~ N(np, np(1-p)). With continuity correction, P(X=k) ≈ Φ((k+0.5−μ)/σ) − Φ((k−0.5−μ)/σ). Optional tail values switch to left or right inequalities.
What happens if trials is not a positive integer?
A binomial experiment needs a positive whole number of trials; zero, negatives, and non-integers are rejected and not billed.
When is the normal approximation considered accurate?
A common rule of thumb is np ≥ 5 and n(1-p) ≥ 5. The probability is still returned when the flag is false.
Why is a continuity correction applied?
The binomial is discrete and the normal is continuous. Spreading the integer k across [k−0.5, k+0.5] keeps a point probability from collapsing to a line of zero area.
What does the normal approximation calculator cost?
The browser tool is free and runs locally.
Related tools
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/stat/normal-approximation \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"trials":100,"p":0.5,"successes":50}'const res = await fetch("https://api.kit.forhosting.com/stat/normal-approximation", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"trials": 100,
"p": 0.5,
"successes": 50
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/stat/normal-approximation",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"trials": 100,
"p": 0.5,
"successes": 50
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/stat/normal-approximation", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"trials":100,"p":0.5,"successes":50}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"trials":100,"p":0.5,"successes":50}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/stat/normal-approximation", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"trials": 100,
"p": 0.5,
"successes": 50
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "stat.normal_approximation",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Limits
max_trials | 10000000 |
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |
Technical notes
A non-positive or non-integer trial count is rejected with invalid_input instead of a silent NaN. The same pure function powers the free browser form and the prepaid API path, so a homework key and a production script never disagree on the same triple. Successful API calls use the published base of $0.002 per item; failed validation is not billed.
How the normal approximation to the binomial is defined
The calculator evaluates those areas with the standard normal cumulative Φ through the error-function identity Φ(z) equals one half times one plus erf of z over square root of two, using the Abramowitz and Stegun rational approximation so every call is pure floating-point arithmetic. There is no simulation, no printed z table, and no network lookup: the same n, p, and k always produce the same JSON, which is what automated graders and reproducible notebooks need.
What you send, what you get back, and when the request fails
Send three required fields: trials, a positive integer n for the number of independent Bernoulli trials; p, a finite success probability strictly between zero and one; and successes, an integer k from zero through n inclusive. The primary result is probability on the unit interval plus percent for quick report copy-paste, and a short formula string restates the Yates identity that was used. An optional tail selects the event: eq (the default) approximates P(X equals k), le approximates P(X at most k), ge approximates P(X at least k), lt approximates P(X strictly less than k), and gt approximates P(X strictly greater than k). The engine also accepts the aliases n and num_trials for the trial count, probability, success_prob, and prob for p, k, x, and target for the success count, and event or comparison for the tail, so a script written in classroom notation does not need a rename step. Missing fields, empty strings, booleans, objects, NaN, and Infinity fail with invalid_input naming the culprit. If p is zero or one the binomial variance vanishes, the z-score is undefined, and the request fails rather than dividing by zero. If successes sits outside zero through n the request fails because that count cannot occur. On success the body echoes the cleaned inputs, returns mean, variance, and stddev of the matching normal, reports np and nq together with a boolean rule_of_thumb_ok that is true when both np and n(1-p) are at least five, and includes the continuity-corrected z_low and z_high around k. The rule-of-thumb flag is diagnostic only: a false value does not reject the call, because the approximation is still defined and many homework items deliberately sit near the boundary.
Where this calculator earns its keep, and how it is priced
Introductory statistics courses assign normal-approximation drills long before students meet software that can sum a binomial mass directly, so a trusted oracle that returns cleaned JSON speeds homework checks, exam keys, and live classroom demos without flipping through a printed z table. Because this capability is a pure parse engine, API pricing is the published base of $0.002 per successful item and failed validation does not consume balance.