Confidence Intervals Inferential Statistics Statistical Tests 22 min read June 15, 2026
BY: Statistics Fundamentals Team
Reviewed By: Minsa A (Senior Statistics Editor)

t-Interval vs z-Interval: How to Choose the Right Confidence Interval

You collected sample data and want to estimate the population mean. Before you can build a confidence interval, one question settles the method: do you know the true population standard deviation? If yes, use the z-interval. If no — the overwhelmingly common case — use the t-interval. The choice controls which critical value you look up, how wide your interval turns out, and whether your inference is statistically valid.

This guide covers both methods side by side: formulas, decision rules, a critical value comparison table, two fully worked examples, a real-time calculator, and answers to the most common exam and research questions about the two intervals.

What You'll Learn
  • ✓ What makes t-intervals and z-intervals different at the distribution level
  • ✓ The single question that determines which interval to use
  • ✓ Full formulas with every variable explained
  • ✓ Why t-intervals are always wider than z-intervals for the same data
  • ✓ Two fully worked examples — one for each interval type
  • ✓ An interactive calculator that computes the interval and recommends the method
  • ✓ A critical value comparison table across confidence levels and sample sizes

What Is the Difference Between a t-Interval and a z-Interval?

The One-Sentence Answer
A z-interval uses the known population standard deviation (σ) and the standard normal distribution. A t-interval uses the estimated sample standard deviation (s) and the Student's t-distribution, which has heavier tails to account for the uncertainty of estimating variability from a sample.
σ known → z-interval  |  σ unknown → t-interval

Both methods construct a confidence interval in the same way: take a sample mean (x̄) and add a margin of error on either side. The structure is always point estimate ± (critical value × standard error). What changes between the two methods is the critical value and the standard error — specifically, which measure of spread goes into computing it.

When σ is known, the standard error is σ/√n, an exact quantity. The critical value comes from the standard normal (Z) distribution and stays the same regardless of sample size: z* = 1.96 for 95% confidence, always.

When σ is unknown — which is the situation in virtually every real study — you substitute s, the standard deviation calculated from your sample. That substitution introduces a second source of randomness: s itself varies from sample to sample. To compensate, statisticians William Sealy Gosset (writing under the pseudonym "Student") developed the t-distribution, which has heavier tails than the normal curve. Those heavier tails push the critical value higher (t* > z*), widening the interval to reflect the genuine extra uncertainty. As sample size grows, s becomes a better estimate of σ and the t-distribution converges toward the normal curve, so the two intervals become nearly identical for large n.

📌
Featured Snippet — Quick Answer

The main difference is whether the population standard deviation (σ) is known. Use a z-interval when σ is known. Use a t-interval when σ is unknown (which is standard in practice). The t-interval uses the sample standard deviation s and a wider critical value that adjusts for each sample size via degrees of freedom.

Formulas: t-Interval and z-Interval Side by Side

Both confidence interval formulas share the same skeleton: a sample mean plus or minus a margin of error. The margin of error is always a critical value multiplied by the standard error of the mean. Where the two methods split is in the critical value source and in whether the population or sample spread goes into the standard error.

When σ is Unknown
t-Interval
x̄ ± t* · (s / √n)
t* from t-distribution with df = n − 1
s = sample standard deviation
When σ is Known
z-Interval
x̄ ± z* · (σ / √n)
z* from standard normal (constant for fixed CL)
σ = population standard deviation

The t-Interval Formula in Full

One-Sample t-Interval for a Population Mean
x̄ ± t* · (s / √n)
= sample mean t* = critical value from t-distribution s = sample standard deviation n = sample size df = n − 1 degrees of freedom s/√n = estimated standard error

The degrees of freedom (df = n − 1) determine which t-distribution curve to use. Each df value gives a slightly different set of tail probabilities. For a sample of 20, df = 19 and t* ≈ 2.093 at 95% confidence. For a sample of 100, df = 99 and t* ≈ 1.984 — very close to 1.960 but still slightly larger. This reflects the fact that even a large sample introduces some uncertainty that the z-distribution ignores. The full t-distribution table lists exact critical values for every df and confidence level.

The z-Interval Formula in Full

One-Sample z-Interval for a Population Mean
x̄ ± z* · (σ / √n)
= sample mean z* = critical value from normal distribution σ = known population standard deviation n = sample size σ/√n = exact standard error

The z* critical value is fixed for each confidence level — it does not change with sample size because the normal distribution has no degrees of freedom parameter. At 90% confidence z* = 1.645; at 95%, z* = 1.960; at 99%, z* = 2.576. These values come from the standard normal (Z) table. Note that the z-interval also covers one-sample proportion intervals, where n and p̂ replace the mean framework entirely.

The t-distribution was derived by W.S. Gosset (1908). "The probable error of a mean." Biometrika, 6(1), 1–25. The normal approximation for known σ follows Fisher, R.A. (1925). Statistical Methods for Research Workers. Critical value conventions follow the NIST Engineering Statistics Handbook.

How to Choose Between a t-Interval and a z-Interval

The decision follows a short logical path. Work through these three checkpoints in order and you will reach the right answer every time.

Decision Path — Which Interval to Use?

Are you estimating a proportion (p)?
Always z-interval (1-Prop z-Int)
Estimating a mean — is the population SD (σ) explicitly given?
→ Yes
z-interval (use σ in the formula)
σ unknown — only sample SD (s) available?
→ Yes
t-interval with df = n − 1
n < 30 with t-interval? Check normality of population
Verify no severe skew or outliers before proceeding
1

Identify what you are estimating

If your goal is a proportion (e.g., the fraction of voters who prefer Candidate A), stop here: you always use a z-interval for proportions, regardless of σ. If you are estimating a population mean μ, continue to Step 2.

2

Check the status of σ

Read the problem statement carefully. Is the population standard deviation (σ) given as a known quantity? If yes, use the z-interval — the standard error is σ/√n, an exact value. If the problem gives only the sample standard deviation (s), you must use the t-interval. In practice, σ is almost never known in advance.

3

Evaluate sample size and normality (for t-interval)

If n ≥ 30, the Central Limit Theorem guarantees an approximately normal sampling distribution, so the t-interval applies without further checks. If n < 30, confirm that the underlying population is roughly bell-shaped with no extreme outliers. A histogram or Q-Q plot can help here.

⚠️
Common Exam Mistake

Using a z-interval because n is large (say, n = 60) even though σ is unknown. A large sample does not make σ "known." The t-interval is still technically correct whenever σ is estimated from data — though for large n, the practical difference is tiny. When in doubt, the t-interval is the safer choice.

Full Comparison: t-Interval vs z-Interval

Feature t-Interval z-Interval
Population SD (σ) Unknown — estimated from sample Known before sampling
Distribution used Student's t-distribution Standard normal distribution
Sample SD (s) Required (in the formula) Not used
Degrees of freedom df = n − 1 (changes critical value) Not applicable
Interval width Wider (larger critical value) Narrower
Critical value at 95%, n = 20 t* = 2.093 (df = 19) z* = 1.960 (constant)
When n → ∞ Converges to z-interval Already at the limit
Proportion estimation Not used Always used (1-Prop z-Int)
How common in practice Very common (σ is almost never known) Rare for means; standard for proportions

Critical Value Comparison by Sample Size

The table below shows how t* shrinks toward z* as sample size grows. This convergence is why the two intervals become indistinguishable for large n — but the t-interval remains technically correct even then.

Confidence Level z* (constant) t* (n = 5, df = 4) t* (n = 10, df = 9) t* (n = 30, df = 29) t* (n = 100, df = 99)
90% 1.645 2.132 1.833 1.699 1.660
95% 1.960 2.776 2.262 2.045 1.984
99% 2.576 4.604 3.250 2.756 2.626

Notice that at n = 5 the 99% t* value is nearly double the z* value. This is the t-distribution's heavy tails at work — with only four degrees of freedom, there is so much uncertainty about σ that the interval must stretch much further to maintain 99% coverage. By n = 100 the gap shrinks to about 2%, which is why many textbooks loosely allow z for large samples when σ is unknown. Using the t-distribution table at high df (or software) gives a precise answer for any sample size without needing to memorize the cutoff.

Worked Examples

Example 1 — t-Interval (σ Unknown)

Worked Example 1 — One-Sample t-Interval

Problem: A clinical researcher measures the resting heart rate of 15 patients. The sample mean is x̄ = 72 bpm and the sample standard deviation is s = 8 bpm. Construct a 95% confidence interval for the true population mean.

🔍
Why t-Interval?

σ is not given — only s = 8 is available. The population SD is unknown, so this is a t-interval problem with df = n − 1 = 14.

t-Interval Formula
x̄ ± t* · (s / √n)
x̄ = 72 bpm s = 8 bpm n = 15 df = 14
1

Identify the method: σ is unknown. Only s = 8 bpm is provided. Use a t-interval with df = 15 − 1 = 14.

2

Find the critical value: At 95% confidence with df = 14, look up the t-table: t* = 2.145.

3

Calculate the standard error:
SE = s / √n = 8 / √15 = 8 / 3.873 = 2.066 bpm

4

Compute the margin of error:
ME = t* × SE = 2.145 × 2.066 = 4.43 bpm

5

Build the interval:
72 ± 4.43 → Lower = 72 − 4.43 = 67.57  |  Upper = 72 + 4.43 = 76.43

✅ Conclusion: We are 95% confident the true average resting heart rate in this population lies between 67.57 bpm and 76.43 bpm.

t* = 2.145 for df = 14 at 95% confidence per the t-distribution table. Methodology follows Gosset (1908) and Moore, D.S., McCabe, G.P. (2009). Introduction to the Practice of Statistics, 6th ed.

Example 2 — z-Interval (σ Known)

Worked Example 2 — One-Sample z-Interval

Problem: A factory monitors the weight of cereal boxes. From years of production records, the population standard deviation is documented as σ = 0.5 oz. An inspector samples 40 boxes and finds x̄ = 16.2 oz. Construct a 95% confidence interval for the true mean weight.

🔍
Why z-Interval?

σ = 0.5 oz is given as a known population parameter. The standard error is exact: σ/√n. Use z* = 1.960 for 95% confidence.

z-Interval Formula
x̄ ± z* · (σ / √n)
x̄ = 16.2 oz σ = 0.5 oz n = 40 z* = 1.960
1

Identify the method: σ = 0.5 oz is explicitly provided. Use a z-interval. (The sample SD is not needed here.)

2

Find the critical value: At 95% confidence, z* = 1.960 from the standard normal table.

3

Calculate the standard error:
SE = σ / √n = 0.5 / √40 = 0.5 / 6.325 = 0.079 oz

4

Compute the margin of error:
ME = z* × SE = 1.960 × 0.079 = 0.155 oz

5

Build the interval:
16.2 ± 0.155 → Lower = 16.045 oz  |  Upper = 16.355 oz

✅ Conclusion: We are 95% confident the true average weight of cereal boxes from this factory is between 16.045 oz and 16.355 oz.

Comparing the two examples side by side shows the width difference plainly. If you ran the first example (heart rates) with a z-interval using the same data — ignoring that σ was unknown — you would get a narrower interval than the t-interval, and that narrower interval would understate your true uncertainty. The t-interval is wider for a reason.

Why Is the t-Interval Always Wider?

At 95% confidence with a sample of 10, t* = 2.262 while z* = 1.960. That difference of 0.302 translates directly into a wider interval. As n grows, the gap closes: at n = 30, t* ≈ 2.045; at n = 100, t* ≈ 1.984. The intervals converge but never fully equate for finite n.

The reason is the distribution's shape. The Student's t-distribution has thicker tails than the standard normal. To capture the same 95% of probability area, the cutoff points (t*) must sit further from center than z*. Those thicker tails are a mathematical statement that s, calculated from a small sample, has its own sampling variability — you might overestimate or underestimate σ from any given dataset, so the interval must account for that.

t* > z*
Always, for any finite n and any confidence level
df = n − 1
Governs how thick the t-distribution tails are
n → ∞
t* converges to z* (intervals merge)

Confidence Interval Calculator (t or z)

Enter your sample data below. The calculator determines which interval to use, computes the margin of error, and returns the confidence interval bounds. If you leave σ blank, it builds a t-interval automatically.

Confidence Interval Calculator

Real-World Applications

The choice between t-intervals and z-intervals shows up across research fields. Below are four common scenarios, each with a clear reason why one method fits over the other.

🏥

Clinical Trials (t-interval)

A researcher measures cholesterol reduction in 25 patients. σ is unknown — only s from the trial data is available. The t-interval with df = 24 gives an honest estimate of uncertainty.

🏭

Quality Control (z-interval)

A long-running production line has σ documented from thousands of measurements. When checking a new batch against that known σ, the z-interval applies directly.

📊

Political Polling (z-interval)

Estimating the proportion of voters who support a policy always uses a z-interval because the one-proportion z-interval formula applies regardless of whether σ is known.

🎓

Educational Research (t-interval)

Comparing mean test scores across two schools uses a two-sample t-interval. Population SDs for each school are not known in advance.

Quick Reference Cheat Sheet

⚡ Decision Rules at a Glance
  • Estimating a proportion: Always z-interval (1-Prop z-Int)
  • Estimating a mean — σ given: z-interval. Use z* from the normal table
  • Estimating a mean — σ unknown: t-interval. Use t* from t-table with df = n − 1
  • n < 30 with t-interval: Verify the population is approximately normal first
  • Large n with unknown σ: Still technically a t-interval — but t* ≈ z* for practical purposes
  • Margin of error too wide: Increase sample size n (wider n → narrower interval)
  • Margin of error too narrow: Possibly an incorrect method — double-check σ status
Scenario Method Critical Value Source Standard Error
Mean, σ known z-Interval Standard normal table σ / √n
Mean, σ unknown t-Interval t-table with df = n − 1 s / √n
Proportion (p) z-Interval Standard normal table √(p̂(1−p̂)/n)
Two means (μ₁ − μ₂) Two-sample t-Interval t-table with Welch's df √(s₁²/n₁ + s₂²/n₂)
Mean of differences (paired) Paired t-Interval t-table with df = n − 1 s_d / √n

FAQs

The difference comes down to whether the population standard deviation (σ) is known. A z-interval uses σ and obtains its critical value from the standard normal distribution. A t-interval uses the sample standard deviation (s) and obtains its critical value from the Student's t-distribution, which has heavier tails to account for the uncertainty introduced by estimating variability from sample data.


Many textbooks allow this as a practical approximation. When n ≥ 30, and especially when n ≥ 100, the t critical value becomes very close to the z critical value, making the resulting intervals nearly identical. However, whenever σ is unknown and estimated from the sample, the t-interval remains the technically correct choice.


The t-distribution accounts for the additional uncertainty created when the population standard deviation is estimated using the sample standard deviation. In small samples, s can vary substantially from sample to sample. The heavier tails increase the critical values and widen confidence intervals, ensuring that the stated confidence level is maintained despite this extra uncertainty.


Rarely. In most research settings, the population standard deviation is unknown and must be estimated from the sample data. This is why t-intervals are generally preferred for estimating population means. Z-intervals are mainly used in teaching examples or specialized industrial applications where process variability has been established from extensive historical data.


As the degrees of freedom increase, the t-distribution gradually approaches the standard normal distribution. The critical value decreases and moves closer to the corresponding z value. With large samples, the difference between t and z intervals becomes negligible, although the t-interval remains the more precise method when σ is unknown.


Confidence intervals and two-sided hypothesis tests at the same significance level provide equivalent conclusions. For example, if a 95% confidence interval for μ does not contain the hypothesized value μ₀, a two-sided test at α = 0.05 would reject the null hypothesis. If μ₀ falls within the interval, the test would fail to reject H₀.

Where to Go Next

The t-interval and z-interval are two tools within the broader confidence interval framework. Understanding them well opens up the rest of inferential statistics. Below are the most directly connected topics on Statistics Fundamentals.

📐

CI for a Mean

The parent guide for constructing confidence intervals for population means, covering both the t and z methods in depth.

📋

t-Distribution Table

Look up exact t* critical values for any degrees of freedom and confidence level, with reading instructions.

📊

Z-Table

Standard normal table for z* critical values and area calculations for z-interval construction.

🔬

One-Sample t-Test

The hypothesis-testing counterpart to the t-interval, using the same t-distribution for significance decisions.

📈

The t-Distribution

Detailed explanation of how the t-distribution is shaped, parameterized, and relates to the normal curve.

🧮

Confidence Interval Calculator

Full-featured online calculator for confidence intervals covering means, proportions, and differences.

📚
External Reference

The technical derivation of the t-distribution is covered in the NIST Engineering Statistics Handbook — t-distribution section. For AP Statistics, the College Board's AP Statistics course page outlines exactly where each interval type appears in the curriculum. Khan Academy's confidence interval unit provides supplementary video walkthroughs for both methods.