Home/Calculator Tools/Confidence Interval Calculator
📊

Confidence Interval Calculator

FREE

Margin of error and bounds at 90%, 95% or 99%

Free · No sign-up required
Loading...

What the confidence interval calculator does

A sample mean is an estimate; a confidence interval says how precise that estimate is. Enter the sample mean, the standard deviation, the sample size and a confidence level (90%, 95% or 99%), and the calculator returns the margin of error and the interval's lower and upper bounds. It is the standard way to report survey results, experimental measurements, A/B test outcomes and quality-control checks. Runs in your browser.

The formula

Margin of error E = z × (s ÷ √n) Interval mean ± E z for 90% = 1.645 z for 95% = 1.960 z for 99% = 2.576 s ÷ √n is the standard error of the mean Sample of 50 orders, mean $84.20, SD $21.50, 95%: standard error = 21.5 ÷ √50 = 3.04 E = 1.96 × 3.04 = 5.96 interval: $78.24 to $90.16

The calculator uses the z (normal) critical value, which is standard when the sample is 30 or larger. For small samples the t distribution gives a slightly wider interval — see the note below.

What 95% confidence actually means

It does not mean there is a 95% chance the true mean is in this particular interval — the true mean is fixed and is either in it or not. It means that if you repeated the sampling many times and built an interval each time, about 95% of those intervals would contain the true mean. In practice it is read as: “values outside this range are implausible given the data.” A narrower interval means a more precise estimate.

What changes the width

FactorEffect on margin of error
Larger sampleShrinks it — by √n, so 4× the sample halves the margin
More variable data (larger SD)Widens it proportionally
Higher confidence levelWidens it: 99% is about 31% wider than 95%
Lower confidence levelNarrows it, at the cost of more intervals missing the truth

To halve the margin of error you need four times the sample size — which is why precise surveys are expensive and why reported margins of ±3% imply samples of about 1,000.

Small samples: the t distribution

When n is below about 30 and the population SD is unknown, the correct critical value comes from the t distribution with n − 1 degrees of freedom, which is larger than z to account for the extra uncertainty in the sample SD. For n = 10 at 95%, t = 2.262 instead of 1.960 — a 15% wider interval. For n = 5, t = 2.776. If your sample is small, multiply the calculator's margin by t ÷ z, or use a statistics package.

nt (95%)vs z = 1.96
52.776+42%
102.262+15%
202.093+7%
302.045+4%
1001.984+1%

Common uses

  • Surveys and polls — reporting a result as 47% ± 3%.
  • A/B tests — checking whether the intervals for two variants overlap (a rough test; a proper comparison uses a two-sample test).
  • Measurement — stating the uncertainty on a lab result or a product dimension from repeated readings.
  • Business metrics — average order value or session length from a sample of records.
  • Quality control — whether a batch mean is within specification.

Frequently asked questions

Which confidence level should I use?

95% is the convention in most fields. Use 99% when a wrong conclusion is costly (medical, safety) and 90% for exploratory work where a narrower interval is more useful.

Should I enter the sample or population standard deviation?

The sample SD (the n − 1 version) — that is what you have from data. The Standard Deviation Calculator reports both.

Can I use this for a proportion (e.g. 62% said yes)?

The formula differs: E = z × √(p(1 − p) / n). For p = 0.62, n = 400: E = 1.96 × √(0.62 × 0.38 / 400) = 4.8%. Enter p as the mean and √(p(1 − p)) as the SD to reuse this calculator.

My interval includes zero. What does that mean?

If you are estimating a difference or an effect, zero being plausible means the data do not show a clear effect at that confidence level.

Does the data need to be normally distributed?

For the mean with n ≥ 30, no — the central limit theorem makes the sample mean approximately normal regardless. For small samples from skewed data, the interval is less reliable.

Are my values stored?

No. The calculation runs in your browser.

More tools in this category

📊
Percentage Calculator
Quickly calculate percentages and ratios
📈
Percentage Change Calculator
Percentage increase or decrease between two values
🔬
Scientific Calculator
Trig, logs, powers and roots with correct operator precedence
Fraction Calculator
Add, subtract, multiply and divide fractions in lowest terms
📊
Standard Deviation Calculator
Mean, variance and standard deviation — population and sample
🔄
Unit Converter
Length, weight, volume, temperature and speed between metric and imperial