Confidence Interval Calculator

Switch between mean and proportion modes to estimate population parameters from sample data.

Inputs — Mean

Common values: 90, 95, 99

Results — Mean

Important Note : This calculator provides a standard confidence interval estimate for quick educational use. For mean intervals, a z-based approach is most appropriate when the population standard deviation is known or when a normal approximation is reasonable. For proportion intervals, results are most reliable with sufficiently large samples.

Use this Confidence Interval Calculator to estimate a confidence interval for either a population mean or a population proportion from sample data. It shows the standard error, critical value, margin of error, and lower and upper bounds, making it useful for statistics homework, survey analysis, research summaries, and quick inference checks.

Reviewed by: AjaxCalculators Editorial Team
Last updated: April 24, 2026
Method source: Standard one-sample confidence interval formulas for a mean and a proportion, with z or t critical values depending on the assumptions
Editorial standards: AjaxCalculators Editorial Policy

What This Confidence Interval Calculator Calculates

This calculator supports two common one-sample confidence interval problems:

  • Confidence interval for a mean
  • Confidence interval for a proportion

Depending on the mode, it can show:

  • Sample statistic
  • Method used
  • Degrees of freedom when applicable
  • Standard error
  • Critical value
  • Margin of error
  • Lower bound
  • Upper bound

How the Confidence Interval Calculator Works

1) Confidence Interval for a Mean

The calculator uses the standard confidence interval structure:

estimate ± (critical value × standard error)

If the population standard deviation σ is known, the standard error is:

SE = σ / √n

and the interval uses a z critical value:

x̄ ± z* × (σ / √n)

If the population standard deviation is unknown and the sample standard deviation s is used instead, the interval uses a t critical value with df = n − 1:

x̄ ± t* × (s / √n)

2) Confidence Interval for a Proportion

For a sample proportion, the point estimate is:

p̂ = x / n

The calculator then uses the standard normal-approximation interval:

p̂ ± z* × √[p̂(1 − p̂) / n]

This is the familiar z-based confidence interval for a proportion and works best when the sample is large enough for the normal approximation to be reasonable.

Assumptions and Important Notes

  • This calculator gives a confidence interval estimate, not a hypothesis-test conclusion by itself.
  • For a mean, use a z interval when the population standard deviation σ is known.
  • For a mean, use a t interval when σ is unknown and you are using the sample standard deviation s.
  • For a proportion, the normal approximation is most reliable when there are at least 10 successes and 10 failures.
  • If the sample is too small or the estimated proportion is too extreme, a more exact interval method may be better than the simple z-based approximation.
  • Higher confidence levels produce wider intervals. Larger sample sizes usually produce narrower intervals.

Worked Example

Example A: Mean Confidence Interval

Suppose a sample has:

  • Sample mean: 52
  • Sample standard deviation: 8
  • Sample size: 25
  • Confidence level: 95%

Step 1: Find the standard error
SE = 8 / √25 = 1.6

Step 2: Choose the correct critical value
Because the sample standard deviation is being used, this is a t interval with df = 24.

Step 3: Find the margin of error
Margin of error = t* × 1.6

Step 4: Build the interval
Confidence interval = 52 ± margin of error

Example B: Proportion Confidence Interval

Suppose a survey finds 72 successes in 120 observations.

Step 1: Find the sample proportion
p̂ = 72 / 120 = 0.60

Step 2: Check the approximation condition
Successes = 72 and failures = 48, so the normal approximation is reasonable.

Step 3: Find the standard error
SE = √[0.60 × 0.40 / 120] ≈ 0.0447

Step 4: Use the critical value for 95% confidence
z* ≈ 1.96

Step 5: Find the margin of error and interval
Margin of error ≈ 1.96 × 0.0447 ≈ 0.0876
Confidence interval ≈ (0.512, 0.688)

How to Use This Confidence Interval Calculator

  1. Select Mean or Proportion mode.
  2. For a mean, enter the sample mean, standard deviation value, sample size, and confidence level.
  3. Choose the correct interpretation of the standard deviation input: σ for known-population z intervals or s for sample-based t intervals.
  4. For a proportion, enter the number of successes, sample size, and confidence level.
  5. Click Calculate to view the critical value, standard error, margin of error, and interval bounds.

How to Interpret the Result

Lower and upper bounds give a plausible range for the true population parameter under the method assumptions.

Margin of error shows how far the interval extends on either side of the sample estimate.

Critical value depends on the confidence level and on whether the method uses z or t.

Method used matters. For mean intervals especially, the choice between z and t affects the width and the interpretation of the interval.

Practical Uses of a Confidence Interval Calculator

  • estimate a population mean from sample data
  • estimate a population proportion from survey or poll data
  • check margin of error in reports and assignments
  • compare how confidence level changes interval width
  • understand when z-based and t-based intervals differ

References

  1. Penn State STAT 500 – Confidence intervals for one mean
  2. Penn State STAT 415 – Confidence interval for a population mean with known standard deviation
  3. Penn State STAT 200 – Confidence interval for a proportion and normal-approximation guidance
  4. NIST – Confidence intervals and the problem of unknown standard deviation

Related Calculators

Disclaimer: This calculator is for educational and general statistical use. A confidence interval is only as good as the method assumptions, the sample quality, and the choice of the correct z or t approach.

More of our calculators...

t-statistic Calculator

Use our t-Statistic Calculator to compute the t value, degrees of freedom, and standard error for one-sample, two-sample, Welch, pooled, or paired t-tests.

t-test Calculator

Use our T-Test Calculator to compute t statistic, p-value, confidence interval, and conclusion for one-sample, Welch, pooled, or paired t-tests.

Outlier Calculator (Tukey Fences)

Use our Outlier Calculator to find low and high outliers with Tukey fences and the IQR method. Get Q1, Q3, IQR, fences, counts, and sorted data fast.

Power Analysis Calculator

Use our Power Analysis Calculator to estimate sample size per group, statistical power, and minimum detectable effect for a two-sample mean test with alpha and standard deviation.

Sample Size Calculator

Use our Sample Size Calculator to estimate sample size for a mean or proportion from confidence level, margin of error, and optional finite population correction.

Margin of Error Calculator

Use our Margin of Error Calculator to find margin of error for a mean or proportion from sample size, confidence level, and z value.

Percentile Calculator

Use our Percentile Calculator to find percentile values from a data set with nearest rank or linear interpolation. Supports raw numbers and value:count input.

Variance Calculator

Use our Variance Calculator to find sample or population variance from a data set. Get mean, variance, standard deviation, SSE, range, and sorted values fast.

IQR (Interquartile Range) Calculator

Use our IQR Calculator(Interquartile Range) to find Q1, Q3, median, and interquartile range from a data set. Supports raw numbers, value:count input, and two quartile methods.