Confidence Interval Calculator (z)
Get a two-sided normal (z) confidence interval for a mean when σ is known, or for a sample proportion. For a mean the interval is x̄ ± z·σ/√n. For a proportion the calculator reports both the Wald interval and the Wilson interval. This is not a Student t interval.
Confidence interval formulas
z is the standard normal critical value Φ⁻¹((1 + level)/2): about 1.645 for 90%, 1.960 for 95% and 2.576 for 99%. The mean interval assumes a known population standard deviation σ (or a large sample where s is treated as σ). It is not a Student t interval; this page does not compute t critical values. For a single z-score, percentile or p-value, use the z-score calculator, which uses the same normal inverse.
Worked examples
Mean, 95%: x̄ = 50, σ = 10, n = 25. The standard error is 10 / √25 = 2. z = 1.960, so the margin is 1.960 × 2 = 3.920. The interval is 46.08 to 53.92.
Proportion, 95%: 80 successes in 100 trials, so p̂ = 0.80. The Wald standard error is √(0.80 × 0.20 / 100) = 0.04, and the Wald interval is 0.80 ± 1.960 × 0.04 = 0.722 to 0.878. The Wilson interval is 0.711 to 0.867. Wilson stays inside (0, 1) and is usually closer to the exact binomial interval when n is modest or p̂ is near 0 or 1; Wald can fall slightly outside 0–1 in those cases.
Critical z and example margins
| Confidence level | Critical z | Margin when σ/√n = 2 | Wald margin when p̂=0.8, n=100 |
|---|---|---|---|
| 80% | 1.28155 | 2.563 | 0.0513 |
| 90% | 1.64485 | 3.290 | 0.0658 |
| 95% | 1.95996 | 3.920 | 0.0784 |
| 98% | 2.32635 | 4.653 | 0.0931 |
| 99% | 2.57583 | 5.152 | 0.1030 |
Critical values from the standard normal inverse CDF, Φ⁻¹((1+level)/2).
When not to use this calculator
- A mean with unknown σ and a small sample needs a t interval, which is not provided here.
- Very small n, or a proportion with only a few successes or failures, is a poor fit for any z interval; consider an exact method.
- The interval is for the population mean or proportion, not a prediction interval for a new observation.
Frequently asked questions
What is a 95% confidence interval for a mean?
For known σ it is x̄ ± 1.960·σ/√n. With x̄ = 50, σ = 10 and n = 25 the interval is 46.08 to 53.92.
What z-value is used for 95%?
z = Φ⁻¹(0.975) ≈ 1.95996, usually written 1.96. 90% uses 1.645 and 99% uses 2.576.
Is this a t-interval?
No. This calculator uses the normal (z) critical value only. A t interval is appropriate when σ is unknown and n is small; that is not implemented here.
What is the difference between Wald and Wilson?
Both are z intervals for a proportion. Wald is p̂ ± z·√(p̂(1−p̂)/n). Wilson shifts the center slightly and is usually more accurate for modest n. For 80/100 at 95%, Wald is 0.722–0.878 and Wilson is 0.711–0.867.
How is this different from the z-score calculator?
The z-score page finds z, a percentile or a p-value from x, μ and σ (or σ/√n). This page uses those z critical values to form an interval around a mean or a proportion.