Confidence Interval Calculator
Calculate confidence intervals for population means and proportions. Find margin of error for 90%, 95%, and 99% confidence levels.
About the Confidence Interval Calculator
A confidence interval calculator computes the range within which a population parameter (typically the population mean) is estimated to fall with a given level of statistical confidence — most commonly 90%, 95%, or 99%. Confidence intervals are among the most important and most misunderstood concepts in statistics. When a news report says "poll results are accurate to within plus or minus 3 percentage points, 19 times out of 20," they are describing a 95% confidence interval. Our free confidence interval calculator accepts your sample data (or summary statistics: sample mean, standard deviation, and n), and returns the confidence interval using either the z-distribution (when population SD is known or n is large) or the t-distribution (when population SD is unknown, which is nearly always the case with real data). It also calculates the margin of error, shows which distribution is appropriate for your data, and explains the correct interpretation of the result.
Formula
CI = x-bar +/- t_(alpha/2, n-1) x (s/sqrt(n)) | Margin of error = critical value x (SD/sqrt(n)) | Use z=1.96 for 95% CI when n>30
How It Works
For a 95% confidence interval for the population mean: CI = sample mean +/- critical value x (standard deviation / sqrt(n)). For z-distribution (large n, known sigma): critical value = 1.96 (for 95% CI). For t-distribution (small n, unknown sigma): critical value = t_(alpha/2, n-1) from t-table with n-1 degrees of freedom. Example: sample of n=25, mean=68, SD=10, seeking 95% CI. Since population SD is unknown, use t-distribution: t_(0.025, 24) = 2.064. CI = 68 +/- 2.064 x (10/sqrt(25)) = 68 +/- 2.064 x 2 = 68 +/- 4.13 = [63.87, 72.13]. Interpretation: we are 95% confident that the true population mean falls between 63.87 and 72.13. Margin of error = half the CI width = 4.13.
Tips & Best Practices
- ✓Critical misconception: a 95% CI does NOT mean "there is a 95% probability the true mean is in this interval." The true mean is a fixed (unknown) value — it is either in the interval or not. The 95% refers to the procedure: if repeated sampling were done 100 times, approximately 95 of the computed intervals would contain the true mean.
- ✓Wider confidence intervals are not failures — a 99% CI is wider than a 95% CI because it captures more uncertainty. Narrower CIs come from larger samples, smaller variance, or accepting lower confidence.
- ✓Sample size and margin of error: to halve the margin of error, you must quadruple the sample size (because n appears under a square root in the formula). This is why doubling sample size gives only a modest improvement in precision.
- ✓Use t-distribution (not z) when n < 30 or when population standard deviation is unknown — which is almost always in practice. For n > 30, the t and z distributions are nearly identical.
- ✓Confidence intervals versus hypothesis tests: a 95% CI is equivalent to a two-tailed hypothesis test at alpha = 0.05. If the null value (e.g., zero for a mean difference) falls outside the 95% CI, the result is statistically significant at p < 0.05.
- ✓Overlap of CIs: when two confidence intervals overlap, it does NOT automatically mean the difference is non-significant at that confidence level. Proper comparison requires computing the CI for the difference directly.
- ✓Bootstrap confidence intervals: for non-normal data or complex statistics, bootstrap resampling methods provide valid CIs without distributional assumptions — increasingly used as computing power makes the resampling approach practical.
- ✓Reporting in research: always report both the CI and the point estimate together. "The mean was 68 (95% CI: 63.9, 72.1)" is a complete and informative statistical summary.
Who Uses This Calculator
Statistics students compute confidence intervals for sample means and proportions as foundational hypothesis testing exercises. Researchers in medicine, psychology, and social science report confidence intervals for study outcomes in academic publications, where journals increasingly require CIs rather than p-values alone as the primary evidence of effect. Pollsters and survey researchers calculate the margin of error (which is the half-width of a 95% CI) for polling results to report statistical uncertainty. Quality engineers use confidence intervals for process capability indices to determine whether a manufacturing process reliably meets specifications. Clinical trials report 95% CIs for treatment effect estimates to allow physicians to judge the clinical significance of results alongside the statistical significance. Data analysts report CIs for A/B test results to communicate uncertainty around conversion rate or metric changes. Economics researchers compute CIs for econometric model coefficients.
Optimised for: USA · Canada · UK · Australia · Calculations run in your browser · No data stored
Frequently Asked Questions
What is a 95% confidence interval?
A 95% CI means if you repeated the study 100 times, 95 of the resulting intervals would contain the true population parameter.