"> Confidence Intervals Explained (With Worked Examples)
Home > Library > Statistics > Confidence Intervals Explained: Definition, Formula & Examples

Published by at August 31st, 2021 , Revised On June 16, 2026

A confidence interval (CI) is a range of values, calculated from sample data, that is likely to contain the true value of an unknown population parameter (such as a mean or a proportion). It is built around a point estimate as point estimate ± margin of error. A 95% confidence level means that if you repeated the same study many times, about 95% of the intervals you constructed would capture the true population value.

Suppose you want to find out how many children in a town leave school before they turn 18. Surveying every child would be expensive and, in practice, almost impossible, so you survey a smaller sample instead. Because a sample is only part of the whole population, each repeat of the survey would give a slightly different result. A confidence interval is how researchers express that uncertainty: rather than reporting a single number, they report a plausible range for the true value.

What Are Confidence Intervals?

A confidence interval is a range of values, bounded above and below a sample statistic such as the mean, that is likely to contain the true population parameter. It quantifies the uncertainty that comes from working with a sample rather than the whole population, and it is usually constructed using inferential methods based on the normal (z) or t-distribution.

Every confidence interval has the same structure:

Confidence interval = point estimate ± margin of error
where the margin of error = critical value × standard error.

The point estimate is your best single guess from the sample (for example, the sample mean). The margin of error is how far either side of that estimate you extend the range, and it depends on two things: how confident you want to be (the critical value) and how precise your estimate is (the standard error). A wider interval reflects more uncertainty; a narrower one reflects more precision.

How to Interpret a Confidence Interval (Correctly)

This is where confidence intervals are most often misunderstood, so it is worth being precise. The single most common mistake is to say:

“There is a 95% probability that the true population mean lies inside this particular interval.” — This statement is incorrect.— Common confidence-interval misconception

Why is it wrong? In classical (frequentist) statistics the true population parameter is a fixed, unknown constant — it is not random. Once you have computed a specific interval, say (102.95, 105.05), the true mean is either inside it or it is not. There is no probability attached to that one realised interval; the probability is 0 or 1, we just do not know which.

The 95% refers to the procedure, not to any single interval. The correct interpretation is:

Correct: “If we repeated this sampling procedure many times and built a 95% confidence interval each time, about 95% of those intervals would contain the true population mean.” The confidence is in the long-run reliability of the method.
  • Right: “We are 95% confident that the interval (102.95, 105.05) contains the true mean” — understood as a statement about the method’s success rate.
  • Wrong: “There is a 95% chance the true mean is between 102.95 and 105.05.”
  • Wrong: “95% of the data values fall within this interval.” (A CI is about the parameter, not the spread of individual observations.)
  • Wrong: “95% of future samples will fall in this interval.”

Why Do Researchers Use Confidence Intervals?

It is rarely feasible to study an entire population, so researchers work with a sample and use a confidence interval to show how well that sample estimate reflects the population. A CI does two valuable things at once: it gives a plausible range for the true value, and it communicates the precision of the estimate. A narrow interval signals a precise, trustworthy estimate; a wide one warns the reader that the estimate is shaky. Reporting an interval is therefore far more informative than reporting a single number with no sense of its reliability, which is why confidence intervals are central to inferential statistics and to interpreting statistical significance.

Confidence Level vs Interval Width

The confidence level (usually 90%, 95% or 99%) is the long-run proportion of intervals that would capture the true parameter. It is chosen by the researcher; 95% is the convention in most social-science and medical research. There is a direct trade-off between confidence and precision: the higher the confidence level, the wider the interval, because demanding more certainty forces you to cast a wider net.

Confidence level Two-tailed z critical value (z*) Relative interval width
80% 1.282 Narrowest
90% 1.645 Narrow
95% 1.960 Standard
99% 2.576 Widest

So a 99% interval is more likely to contain the true value than a 90% interval, but it is also less precise (wider). Choosing a confidence level is a judgement about how much you are willing to trade precision for reliability.

Factors that affect the width of a confidence interval

  • Sample size (n): larger samples give a smaller standard error and therefore a narrower, more precise interval. Because the standard error shrinks with √n, quadrupling the sample size roughly halves the margin of error.
  • Variability in the data: the more spread out the data (a larger standard deviation), the larger the standard error and the wider the interval.
  • Confidence level: a higher confidence level (e.g. 99% vs 95%) uses a larger critical value and widens the interval.
  • Proportion near 50% (for proportions): for a percentage estimate, uncertainty is greatest near 50/50. A 51%/49% split carries more sampling error than a 98%/2% split, regardless of sample size.
sample size (n) →
A higher confidence level gives a wider interval.

“The confidence level is the frequency of possible confidence intervals that contain the true value of the unknown population parameter.”— NIST/SEMATECH e-Handbook of Statistical Methods

How to Calculate a Confidence Interval

Which formula you use depends on whether the population standard deviation is known. When it is known (or the sample is large), use the z-distribution. When it is unknown and estimated from a small sample, use the t-distribution, which has heavier tails to account for the extra uncertainty. To decide between them and other tests, see our guide on which statistical test to use.

1. Using the normal (z) distribution — σ known

The formula for a confidence interval for a mean when the population standard deviation σ is known is:

CI = x̄ ± z* × (σ / √n)
  • x̄ = the sample mean (the point estimate)
  • z* = the critical value of the z-distribution for the chosen confidence level
  • σ = the population standard deviation
  • n = the sample size; √n is its square root
  • σ / √n = the standard error of the mean
Example (z-interval): The mean weight of a sample of 5 children was 104 pounds, with a known population standard deviation of 1.2 pounds. Construct a 95% confidence interval for the true mean weight.

Step 1 – find the critical value. For 95% confidence, 2.5% sits in each tail. Looking up an area of 0.975 in the z-table gives z* = 1.96.
Step 2 – compute the standard error. σ / √n = 1.2 / √5 = 1.2 / 2.2361 = 0.5367.
Step 3 – compute the margin of error. z* × SE = 1.96 × 0.5367 = 1.05.
Step 4 – build the interval. Lower: 104 − 1.05 = 102.95. Upper: 104 + 1.05 = 105.05.

The 95% CI is (102.95, 105.05). Interpretation: if we repeated this procedure many times, about 95% of the intervals produced would contain the true mean weight.

2. Using the t-distribution — σ unknown, small sample

When the population standard deviation is unknown and estimated from a small sample, replace z* with the t critical value and σ with the sample standard deviation s:

CI = x̄ ± t* × (s / √n), with degrees of freedom df = n − 1.
Normalt (df 3)
The t-distribution (dashed) has heavier tails than the normal; they converge as df rise.
Worked Example (t-interval): A sample of 10 college students had a mean weight of 150 pounds and a sample standard deviation of 20 pounds. Find a 95% confidence interval for the true mean weight.

Step 1 – degrees of freedom. df = n − 1 = 10 − 1 = 9.
Step 2 – tail area. (1 − 0.95) / 2 = 0.025 in each tail.
Step 3 – t critical value. For df = 9 and a tail area of 0.025, the t-table gives t* = 2.262.
Step 4 – standard error. s / √n = 20 / √10 = 20 / 3.1623 = 6.325.
Step 5 – margin of error. t* × SE = 2.262 × 6.325 = 14.31.
Step 6 – build the interval. Lower: 150 − 14.31 = 135.69. Upper: 150 + 14.31 = 164.31.

The 95% CI is (135.69, 164.31).

Steps to calculate any confidence interval

  1. Calculate the point estimate from your sample (e.g. the sample mean x̄).
  2. Choose a confidence level (commonly 95%) and find the matching critical value (z* or t*).
  3. Calculate the standard error of the estimate (σ/√n or s/√n).
  4. Multiply the critical value by the standard error to get the margin of error.
  5. Add and subtract the margin of error from the point estimate to get the upper and lower bounds.

Struggling to interpret your confidence intervals?

ResearchProspect to the rescue!

Our experts run and explain the analysis correctly with our statistical analysis service.

Frequently Asked Questions

What does a 95% confidence interval actually mean?

It means that if you repeated the same sampling procedure many times and built a 95% interval each time, about 95% of those intervals would contain the true population parameter. It does not mean there is a 95% probability that the true value lies inside one specific interval — the parameter is fixed, so a given interval either contains it or it does not.

For a two-tailed interval the critical z-values are: 80% → z* = 1.282, 85% → z* = 1.440, 90% → z* = 1.645, 95% → z* = 1.960 and 99% → z* = 2.576. You find each one by looking up the cumulative area 1 − α/2 in a standard normal table.

Subtract the confidence level from 1 to get the total significance level α, then divide by 2 to split it between the two tails. For a 95% interval: (1 − 0.95)/2 = 0.05/2 = 0.025 in each tail. You then look up the area 1 − 0.025 = 0.975 to find the critical value.

The confidence level is the percentage (e.g. 95%) describing how often the method captures the true value over many repeats. The confidence interval is the actual range of values (e.g. 102.95 to 105.05) produced for a particular sample at that level. In short: the level is the reliability of the method; the interval is the result.

Use a z-interval when the population standard deviation is known or the sample is large. Use a t-interval when the population standard deviation is unknown and estimated from a small sample. The t-distribution has heavier tails, giving slightly wider intervals to account for the extra uncertainty, and it depends on the degrees of freedom (n − 1).

Wider. A higher confidence level uses a larger critical value, so the margin of error grows and the interval widens. There is a trade-off between confidence and precision — a 99% interval is more reliable but less precise than a 90% one. The only way to be both more confident and more precise is to increase the sample size.

About Owen Ingram

Avatar for Owen IngramIngram is a dissertation specialist. He has a master's degree in data sciences. His research work aims to compare the various types of research methods used among academicians and researchers.

WhatsApp Live Chat