Confidence Interval Calculator

Choose an interval method that matches the information available instead of applying one formula to every sample. Known population standard deviation uses a z critical value, an estimated mean uses Student’s t, and an integer success count with sample size uses the Wilson interval.

Inputs

Instant calculation

Required
-1000000000000 ≤ x ≤ 1000000000000
0 ≤ x ≤ 1000000000000
1 ≤ x ≤ 10000000; x ∈ ℤ

Result

Instant calculation

Lower confidence bound
97.060054
Upper confidence bound
102.939946
Margin of error
2.939946
Standard error
1.5
Z critical value
1.959964

How to use this calculator

Enter interval method, confidence level, sample size, and either the mean with standard deviation or the whole-number success count required by that method.

Review sampling independence, population shape, how the standard deviation was obtained, sample design, and whether the chosen level was prespecified.

Read lower confidence bound, upper confidence bound, margin of error, standard error, point estimate, and critical value as applicable and compare the displayed assumptions before reusing the answer.

Formula

Mean interval = sample mean ± critical value × standard deviation ÷ √n. The t method uses n − 1 degrees of freedom. The Wilson proportion interval adjusts both center and half-width by z² ÷ n instead of using the fragile Wald interval.

Worked example

For mean 100, known standard deviation 15, n = 100, and 95% confidence, the z interval is about 97.06 to 102.94 with a margin near 2.94.

Reference guide

Formula details and result guidance

Follow the variables, derivation, precision rule, and worked cases below to reproduce the calculation independently.

Variables

Formula variables, units, and roles
SymbolMeaningUnitRole
θ̂Sample estimatemeasured quantity or proportionInput
x, nSuccessful observations and sample sizewhole observationsInput
SEStandard errorsame as estimateIntermediate
q*Critical quantilenoneIntermediate
L, ULower and upper boundssame as estimateOutput

Derivation

  1. A z mean interval with known population standard deviation uses x̄ ± z*σ/√n.
  2. A t mean interval with sample standard deviation uses x̄ ± t*s/√n with n − 1 degrees of freedom.
  3. For a proportion, the Wilson interval adjusts both center and half-width and remains within [0, 1].

Rounding and precision

Critical values and standard errors are retained without intermediate display rounding; bounds show up to 6 decimal places. The selected confidence level is a repeated-sampling coverage target, not a probability assigned to fixed bounds after calculation.

Worked and boundary examples

Worked example

Known-sigma mean

Input
x̄ = 100; σ = 15; n = 100; 95%
Output
≈ [97.0601, 102.9399]

The z critical value is about 1.96.

Worked example

Small-sample t interval

Input
x̄ = 10; s = 2; n = 16; 95%
Output
≈ [8.934, 11.066]

Using t accounts for estimating variability with 15 degrees of freedom.

Boundary case

No observed successes

Input
x = 0; n = 20; Wilson 95%
Output
Lower bound 0; upper bound above 0

Wilson avoids a misleading zero-width interval at the boundary.

Common mistakes

  • Using a z interval with a sample standard deviation as if population variability were known.
  • Interpreting 95% confidence as a 95% posterior probability for the already computed interval.
  • Ignoring sampling design, dependence, bias, or nonrepresentative data because the arithmetic produces bounds.

How to interpret the result

Under the selected model and repeated use of the procedure, the stated share of intervals is designed to cover the parameter. The single computed interval still depends on the sample and assumptions.

Scope

Appropriate for

  • Reproducing a z, t, or Wilson interval from summary statistics.
  • Comparing how sample size and confidence level change interval width.

Do not use for

  • Repairing biased or dependent samples through arithmetic alone.
  • Making clinical, policy, or safety decisions without subject-matter review.

Evidence and sources

Assumptions and limits

  • The interval quantifies repeated-sampling uncertainty under the selected model. It does not mean the fixed parameter has the displayed probability of lying inside this one computed interval.
  • Confidence Interval Calculator uses only the values entered in the form and does not infer an institution, policy, contract, population, or project condition.
  • Working calculations retain full numeric precision; display rounding is separate and should not be copied into a later calculation when the unrounded value is available.

Sources

Related calculators

Verification

How this calculator is checked

Trust comes from reproducible evidence, not model confidence. You can inspect the formula, assumptions, worked example, and cited sources on this page.

Frequently asked questions

How does the Confidence Interval Calculator work?

Mean interval = sample mean ± critical value × standard deviation ÷ √n. The t method uses n − 1 degrees of freedom. The Wilson proportion interval adjusts both center and half-width by z² ÷ n instead of using the fragile Wald interval.

What should I enter in the Confidence Interval Calculator?

Enter interval method, confidence level, sample size, and either the mean with standard deviation or the whole-number success count required by that method, then verify sampling independence, population shape, how the standard deviation was obtained, sample design, and whether the chosen level was prespecified.

When should I avoid relying only on the Confidence Interval Calculator?

The interval quantifies repeated-sampling uncertainty under the selected model. It does not mean the fixed parameter has the displayed probability of lying inside this one computed interval.

Last updated 2026-08-25 · mean-z-mean-t-wilson-counts-v2 · content-2026-08-22 · Published by YunFanLabs