Confidence Interval Calculator

Confidence Interval

[94.12, 105.88]

The Numbers

  • Standard Error: 3
  • Margin of Error: ±5.88
  • Critical Value (z): 1.96

Compare Calculations

Downloads

Includes your inputs and results for this calculation, plus any additional calculations you've compared.

Good to Know

This calculator uses the z-distribution, which assumes a large sample size or a known population standard deviation. For small samples (fewer than about 30) with an estimated standard deviation, the t-distribution is technically more accurate and will produce a slightly wider interval than shown here.

How This Calculator Works

A confidence interval is a range of values, built around a sample’s own mean, that likely contains the true population mean. Enter a sample’s mean, standard deviation, and size, choose a confidence level, and this calculator finds the range within which the actual population mean probably falls.

A “95% confidence interval,” for example, means that if you repeated the same sampling process many times, about 95% of the intervals it produced would contain the true population mean. It does not mean there’s a 95% chance the true mean falls inside this one specific interval — a common, technically-incorrect way people phrase it. A wider interval (higher confidence level) casts a wider net and is more likely to contain the true mean; a narrower interval is more precise but less certain.

The Formula

Standard Error=sn\vE{\text{Standard Error}} = \frac{\vA{s}}{\sqrt{\vB{n}}} Margin of Error=z×Standard Error\vF{\text{Margin of Error}} = \vC{z} \times \vE{\text{Standard Error}} Confidence Interval=xˉ±Margin of Error\text{Confidence Interval} = \vD{\bar{x}} \pm \vF{\text{Margin of Error}}

Where s\vA{s} is the sample’s standard deviation, n\vB{n} is the sample size, z\vC{z} is the critical value for the chosen confidence level (looked up from the standard normal distribution), and xˉ\vD{\bar{x}} is the sample mean. A bigger sample size shrinks the standard error — and therefore the whole interval — since more data gives a more precise estimate of the true mean.

Worked Example

A sample of 25 items has a mean of 100 and a standard deviation of 15, at a 95% confidence level (a critical value of z = 1.96):

    1. Standard error: Standard Error=15÷25=3\vE{\text{Standard Error}} = \vA{15} \div \sqrt{\vB{25}} = \vE{3}.
    2. Margin of error: Margin of Error=1.96×3=5.88\vF{\text{Margin of Error}} = \vC{1.96} \times \vE{3} = \vF{5.88}.
    3. Confidence interval: Confidence Interval=100±5.88=[94.12,105.88]\text{Confidence Interval} = \vD{100} \pm \vF{5.88} = [94.12, 105.88].

So the true population mean is likely (with 95% confidence) somewhere between 94.12 and 105.88.

Source: Standard statistical inference formula using the z-distribution.

Frequently Asked Questions

What does "95% confidence" actually mean?

It means that if you repeated the same sampling process many times, about 95% of the resulting intervals would contain the true population mean. It does NOT mean there is a 95% chance the true mean falls inside this ONE specific interval — a common but technically incorrect way to phrase it.

Why does a bigger sample size shrink the interval?

The standard error (and therefore the margin of error) is divided by the square root of the sample size, so more data produces a more precise — and narrower — estimate of the true population mean.

Should I use the z-distribution or the t-distribution?

The z-distribution (used here) is standard for large samples (n of about 30 or more) or when the population's true standard deviation is already known. For a small sample with only an estimated standard deviation, the t-distribution is technically more accurate and produces a slightly wider interval.

What happens if I choose a higher confidence level?

A higher confidence level (e.g. 99% instead of 95%) uses a larger critical z-value, which widens the interval. This is an unavoidable trade-off: casting a wider net makes it more likely the true mean is actually inside the interval, at the cost of a less precise estimate.