
Confidence Interval
Confidence interval for a mean from sample size and standard deviation.
95% confidence interval
95.84 – 104.16
± 4.158
Margin of error
4.1578
Standard error
2.1213
z-value
1.96
AI Breakdown & Smart Takeaway
Plain-English insight on your numbers
Get a personalized explanation of what these results mean — and how to improve them.
How the Confidence Interval works
This Confidence Interval calculator estimates a population mean's likely range using your sample size, sample mean, and standard deviation — giving researchers, students, and analysts a statistically sound CI without manual computation.
A confidence interval (CI) is a range of values, derived from sample data, that likely contains the true population mean with a specified level of certainty. When you enter your sample mean, standard deviation, and sample size, the calculator applies the appropriate statistical formula to produce a lower and upper bound. The chosen confidence level — typically 90%, 95%, or 99% — determines how wide that range is: higher confidence demands a wider interval to be more certain of capturing the true parameter.
The calculator automatically decides whether to use the Z-distribution or the t-distribution depending on your sample size and whether the population standard deviation is known. For large samples (n ≥ 30) or known population standard deviation, the Z-score (e.g., 1.96 for 95% confidence) is used. For smaller samples with unknown population standard deviation, the t-score from Student's t-distribution is applied, which accounts for additional uncertainty by using degrees of freedom (n − 1). This distinction matters because using a Z-score on a small sample underestimates the margin of error and produces an overconfident interval.
The margin of error (MOE) is the half-width of the confidence interval and is the most sensitive component of the result. It is directly proportional to the critical value and standard deviation, and inversely proportional to the square root of sample size. This square-root relationship means that to halve your margin of error, you must quadruple your sample size — a crucial insight for study design and survey planning. Reducing variability in your measurements (lowering standard deviation) also narrows the CI, but this is often harder to control in practice than increasing n.
A common misconception is that a 95% CI means there is a 95% probability that the true mean lies within this specific interval. Technically, the true mean is fixed — it either is or isn't in the interval. The correct interpretation is that if you repeated the sampling process many times, 95% of the resulting intervals would contain the true population mean. Practically, this means CI results should be reported alongside sample size and confidence level, and users should avoid over-interpreting a single interval as a definitive answer rather than a probabilistic estimate.
Formula
CI = x̄ ± z · (σ / √n)
Pro tips
- Always match your distribution to your data: use the t-distribution for small samples (n < 30) with unknown population standard deviation — the calculator handles this automatically, but understanding why prevents misinterpretation of results.
- If your CI is too wide to be useful, prioritize increasing sample size over raising confidence level, since quadrupling n halves the margin of error, while dropping from 99% to 95% confidence offers only modest narrowing.
- Report the full CI (lower bound, upper bound, confidence level, and n) in any written analysis — a single mean without its interval omits the statistical uncertainty that makes the result meaningful.
- Check that your data meets CI assumptions: observations should be independent and approximately normally distributed (or n ≥ 30 by the Central Limit Theorem). Outliers inflate standard deviation and artificially widen the interval.
- When comparing two groups, look at whether their 95% confidence intervals overlap — non-overlapping intervals strongly suggest a statistically significant difference, though a formal hypothesis test remains the rigorous approach.
Key terms
- Confidence Interval (CI)
- — A range of values calculated from sample data that is expected to contain the true population parameter with a stated probability (the confidence level).
- Confidence Level
- — The percentage of times (e.g., 95%) that a CI constructed from repeated random samples would contain the true population mean.
- Margin of Error
- — The half-width of a confidence interval, representing the maximum expected difference between the sample estimate and the true population value.
- Critical Value
- — The Z-score or t-score that defines the boundary of the confidence interval based on the chosen confidence level and sample size.
- Standard Error
- — The standard deviation of the sampling distribution of the mean, calculated as s divided by the square root of n, measuring how much the sample mean is expected to vary.
- Degrees of Freedom
- — A value equal to n − 1 used when applying the t-distribution, reflecting the number of independent pieces of information available to estimate the population parameter.