Skip to content
ENExplore Calculators

Confidence Interval Calculator

Build confidence intervals for a mean or proportion at any confidence level.

About Confidence Interval Calculator

A confidence interval gives a range of plausible values for an unknown population parameter. A 95 % interval means: if you repeated the study many times, 95 % of the constructed intervals would contain the true parameter. It does NOT mean the parameter has a 95 % chance of being in this specific interval. When σ is known you use a z critical value; when σ is estimated from the sample you use a t critical value (with n−1 degrees of freedom), which produces a wider interval that accounts for the added uncertainty.

Formulas

Mean (σ known)

x̄ ± z* × σ/√n

z*
Critical z value
σ
Population std deviation
n
Sample size

Mean (σ unknown)

x̄ ± t* × s/√n, with df = n−1

Proportion

p̂ ± z* × √(p̂(1−p̂)/n)

Worked example

With the default values below, Confidence Interval Calculator returns Lower bound of 46.4216. Change any input above and every figure here is recalculated in your browser.

Inputs used

Interval typeone of Mean — σ known (z-interval), Mean — σ unknown (t-interval), Proportion (z-interval)
Mean — σ known (z-interval)
Sample mean (x̄)
50
Population std deviation (σ)minimum 0
10
Sample std deviation (s)minimum 0
10
Sample size (n)minimum 2
30
Sample proportion (p̂)accepts 0–1
0.6
Sample size (n)minimum 1
100
Confidence level (%)accepts 50–99.99
95

Results

Lower bound
46.4216
Upper bound
53.5784
Margin of error
3.5784
Critical value (z* or t*)
1.9600
Standard error
1.825742

Step by step

  1. 1Critical z value= 1.9600
  2. 2Standard error= 1.8257
  3. 3Margin of error= 3.5784
  4. 4Confidence interval= [46.4216, 53.5784]

Assumptions and limits

  • The result is derived only from the 8 inputs listed above. Anything not among them is not part of the calculation.
  • In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
  • Figures are rounded for display to 6 decimal places, so totals built from several rounded parts can differ slightly from the unrounded arithmetic.

How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.

Frequently Asked Questions

What does a 95 % confidence interval actually mean?

It means the procedure used to construct the interval would capture the true parameter 95 % of the time across repeated samples. For this particular interval, the parameter is either inside it or it isn't — there is no probability attached to that fact.

When should I use t instead of z?

Always use t when the population standard deviation σ is unknown and you are estimating it from the sample. The t-distribution has heavier tails than the normal, producing a wider interval that honestly reflects the extra uncertainty. As n grows the t-distribution converges to normal, so the choice matters most for small samples (n < 30).

Why does increasing the confidence level widen the interval?

A higher confidence level requires a larger critical value (z* or t*), which directly multiplies the margin of error. You are asking for more certainty, so you pay with precision.

Why is there a warning about the normal approximation for proportions?

The z-interval for a proportion relies on the normal approximation to the binomial. This approximation requires np̂ ≥ 5 and n(1−p̂) ≥ 5. When either condition fails — especially for extreme proportions or very small n — the interval is unreliable. Consider an exact Clopper-Pearson interval instead.

Confidence Interval Calculator (Math) | Calcrivo