Confidence Interval Calculator: Mean & Proportion

Confidence Interval Calculator

Confidence Interval Calculator

Calculate standard error and confidence intervals for population means ($\mu$) and proportions ($p$).

Mean (μ)
Proportion (p)

Result

Z-Statistic
Lower Bound
Upper Bound
[ — , — ]
Margin of Error:

Normal Distribution Visualization

Understanding Confidence Intervals

A Confidence Interval (CI) provides a range of plausible values for an unknown population parameter (like the mean $\mu$ or proportion $p$). It is constructed from sample data. For example, a “95% Confidence Interval” means that if we took many samples and built a CI from each, 95% of them would contain the true population parameter.

Calculating for Means

For the population mean $\mu$, the formula depends on the sample size ($n$) and whether the population standard deviation ($\sigma$) is known.
Large Sample ($n \ge 30$): We use the Z-statistic (Standard Normal Distribution). $$ \bar{x} \pm Z_{\alpha/2} \left( \frac{s}{\sqrt{n}} \right) $$
Small Sample ($n < 30$): We use the T-statistic (Student’s t-Distribution), which has “heavier tails” to account for the uncertainty in estimating the standard deviation. $$ \bar{x} \pm t_{\alpha/2, df} \left( \frac{s}{\sqrt{n}} \right) $$

Calculating for Proportions

For population proportion $p$, we typically use the Z-statistic approximation, provided the sample size is large enough ($np \ge 10$ and $n(1-p) \ge 10$). $$ \hat{p} \pm Z_{\alpha/2} \sqrt{\frac{\hat{p}(1-\hat{p})}{n}} $$

FAQ

What does 95% confidence actually mean?
It does not mean there is a 95% probability that the specific interval you calculated contains the mean. Once calculated, the interval either contains the mean or it doesn’t. “95% confidence” refers to the reliability of the method: 95% of such intervals constructed from repeated sampling will contain the true parameter.
When should I use T instead of Z?
Use the T-statistic when the population standard deviation ($\sigma$) is unknown and the sample size is small ($n < 30$). If $n \ge 30$, the T-distribution converges to the Z-distribution, so Z is often used for simplicity, though T is technically more correct whenever $\sigma$ is unknown.
How can I reduce the Margin of Error?
You can reduce the Margin of Error (make the interval narrower) by either: 1. Increasing the sample size ($n$): Dividing by a larger number reduces the standard error. 2. Decreasing the confidence level: Going from 99% to 90% reduces the critical value (Z or T), narrowing the range (but increasing the risk of missing the true mean).

UNDERGRADUATE