A z-test answers the same basic question as a t-test — is the difference you observed bigger than random sampling noise would produce? — but it's used specifically when the population standard deviation is already known, rather than estimated from your sample. This calculator runs the three most common z-test variants (one-sample, two-sample, and one-proportion) from summary statistics you already have.
Which z-test do I need?
Use the one-sample test when you're comparing a single group's average against a known or hypothesized value, and you know the population's true standard deviation (a well-characterized measurement instrument, a manufacturing spec with a documented process variance, or a standardized test with a published population σ). Use the two-sample test when you have two separate, independent groups with known population standard deviations and want to know if their means differ. Use the proportion test when your data is a count of successes out of a total — a poll result, a defect rate, a conversion rate — compared against a hypothesized rate.
Reading the z-statistic and p-value
The z-statistic measures how many standard errors separate the observed difference from zero (or from µ₀/p₀) — the larger its absolute value, the less compatible the data are with the null hypothesis of no difference. Unlike a t-test, a z-test has no degrees-of-freedom concept: because σ (or, for a proportion, the null-hypothesis variance) is treated as known rather than estimated, the sampling distribution is exactly the standard normal curve regardless of sample size. The p-value converts z into a probability: it's the chance of seeing a z-statistic this extreme (or more) if the null hypothesis were actually true. Compare it to your significance threshold α (conventionally 0.05) — p < α means reject the null hypothesis, p ≥ α means you don't have enough evidence to do so.
z-test vs. t-test — when is σ really known?
In practice, the true population standard deviation is rarely known with certainty — most real-world analyses should use a t-test, which estimates variability from the sample itself and appropriately widens the result for that uncertainty. A z-test is the right tool when σ genuinely comes from an external, authoritative source (a calibrated instrument's published precision, a large historical dataset, or — for proportions — the null hypothesis itself, since a proportion's variance is mathematically determined by its own value). As a practical shortcut, when the sample size is large (conventionally n ≥ 30), the t-distribution converges closely to the normal distribution, so a z-test and a t-test give nearly identical results even if σ was technically estimated from the sample.