Confidence Interval Calculator

Quantify the certainty of your statistical estimates with precise upper and lower bounds.

Sample Parameters

Confidence Interval Calculator

A confidence interval gives a range of plausible values for a population parameter — telling you not just your estimate, but how precise that estimate is. This calculator builds CIs for means and proportions at any confidence level.

How to Use This Calculator

  1. Select CI for a mean or CI for a proportion.
  2. For mean: enter sample mean, standard deviation, and sample size.
  3. For proportion: enter number of successes and total sample size.
  4. Select the confidence level (90%, 95%, or 99%).
  5. Click Calculate to see the CI bounds and margin of error.

CI Formulas

For a mean (large sample): x̄ ± z* × (σ/√n)

For a proportion: p̂ ± z* × √[p̂(1−p̂)/n]

  • z* = 1.645 (90% CI), 1.960 (95% CI), 2.576 (99% CI)
  • For small samples (n < 30), use t* instead of z*

Example: CI for a Mean

Sample: n=100 | Mean = 52 | SD = 8 | Confidence: 95%

  • Standard error: 8/√100 = 0.8
  • Margin of error: 1.96 × 0.8 = 1.568
  • 95% CI: [50.43, 53.57]
  • Interpretation: We are 95% confident the true population mean is between 50.43 and 53.57.

Example: CI for a Proportion

Survey: 320 of 500 respondents support the policy (64%) | 95% CI

  • p̂ = 0.64 | SE = √(0.64 × 0.36 / 500) = 0.0215
  • Margin of error: 1.96 × 0.0215 = 0.042 (±4.2%)
  • 95% CI: [59.8%, 68.2%]

Common Mistakes to Avoid

  • Saying "there is a 95% probability the true value is in the CI" — The true value is fixed; it either is or isn't in the interval. The correct interpretation: 95% of intervals constructed this way will contain the true value.
  • Using z* for small samples — With n < 30 and unknown population SD, use the t-distribution (t* from t-table with n−1 degrees of freedom).
  • Wider CI = less useful, narrower = more — Narrow CIs require larger samples. Balance between precision and the cost/feasibility of collecting more data.

Frequently Asked Questions

What is the margin of error?

The margin of error (MOE) is half the width of the confidence interval. A CI of [47, 53] has a MOE of ±3. It quantifies the maximum expected difference between your estimate and the true value at your chosen confidence level.

How do I get a narrower confidence interval?

Increase sample size (most effective), reduce variability in measurements, or lower the confidence level (e.g., from 99% to 95%). Increasing sample size 4x roughly halves the margin of error (√4 = 2).

What is a 95% vs. 99% confidence interval?

Higher confidence (99%) gives a wider interval — you're more certain, but less precise. For most research, 95% confidence strikes the best balance between precision and certainty.

Conclusion

Confidence intervals transform point estimates into honest, uncertainty-quantified ranges. They're essential for research reports, polls, clinical trials, and any decision based on sample data.

Related: Z-Score Calculator | Sample Size Calculator | Statistics Calculator

Increasing the sample size (n) is the most effective way to narrow the confidence interval and increase the precision of your results without lowering your confidence level.