Z.TEST Function

Excel Functions › Statistical

Excel 2010+ Statistical

The Excel Z.TEST function returns the one-tailed probability value of a z-test — the chance of observing a sample mean greater than the value x if the true population mean were x.


Quick answer:
=Z.TEST({3,6,7,8,6,5,4,2,1,9},4) one-tailed p = ~0.0905

Syntax

=Z.TEST(array, x, [sigma])
ArgumentDescription
arrayRequiredThe array or range of data to test against the hypothesized mean.
xRequiredThe value to test — the hypothesized population mean.
sigmaOptionalThe known population standard deviation. If omitted, Excel uses the sample standard deviation of array.

How to use it

Z.TEST answers a one-tailed question: given your data, how likely is it that the population mean is at least x? It returns P(Z > z), where the z-score is built from the sample mean, x, and the standard deviation.

=Z.TEST({3,6,7,8,6,5,4,2,1,9},4) // one-tailed = 0.0905
=Z.TEST({3,6,7,8,6,5,4,2,1,9},4,2) // known sigma=2 = 0.0410

If you omit sigma, Excel substitutes the sample standard deviation of the array. Supply sigma only when the population standard deviation is genuinely known. For a two-tailed probability, double the smaller tail: =2*MIN(Z.TEST(array,x), 1-Z.TEST(array,x)).

Reading the result: a small value (say below 0.05) means the sample mean sits well above x — evidence that the true mean exceeds x. A value near 0.5 means the sample mean is right around x.

Try it: interactive demo

Live demo

Pick a Z.TEST example to see the formula and its result.

Result:

Practice workbook

📊
Download the free Z.TEST practice workbook
Every example on this page, ready to open in Excel — plus practice challenges with answers on a separate tab. No sign-up required.

Frequently asked questions

Is Z.TEST one-tailed or two-tailed?
It returns the one-tailed probability that a sample mean would exceed x. For a two-tailed test use =2*MIN(Z.TEST(array,x), 1-Z.TEST(array,x)).
What happens if I leave out sigma?
Excel uses the sample standard deviation of the array instead of a known population value. Provide sigma only when the population standard deviation is actually known.
What is the difference between Z.TEST and ZTEST?
They are the same test. Z.TEST is the modern name (Excel 2010+); ZTEST is the legacy compatibility version. Use Z.TEST in current workbooks.
When should I use Z.TEST instead of T.TEST?
A z-test assumes a large sample or a known population standard deviation. With small samples and unknown variance, a t-test (T.TEST) is more appropriate.

Master functions like this in one day

This page covers one function. Our Excel Formulas and Functions class covers the 30 that matter most — live, hands-on, taught by professionals in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or online.

See the Formulas & Functions Class

Related functions: NORM.S.DIST · STANDARDIZE · T.TEST · NORM.DIST · CONFIDENCE.NORM