Z-Score Calculator
Turn a value, a mean and a standard deviation into a z-score, then into the share of a normal distribution below it, above it and outside it either way.
z-score
2
Share of the curve below (percentile)
0.97724987
Share above (one-tailed p)
0.022750132
Share further out either way (two-tailed p)
0.045500264
z = (x − μ) / σ · P(Z < z) = Φ(z)
A z-score rewrites a number as a distance. Instead of "158 centimetres" it says "1.2 standard deviations below the mean", which lets you compare a height with a test score with a blood pressure, none of which share units. Feed it back through the normal distribution and the same number becomes a percentile and a p-value: how much of the curve sits below your value, how much sits beyond it, and how much sits that far out in either direction.
How it is calculated
z = (x − μ) / σ · P(Z < z) = Φ(z)
The subtraction moves the mean to zero and the division rescales the spread to one, which is all a z-score is. The probabilities are a separate step and they carry an assumption the z-score itself does not: turning z into a percentile requires the data to be normally distributed. For skewed data the z-score is still a perfectly good statement of distance, while the percentile beside it is wrong — sometimes badly. Income is the standard example: two standard deviations above mean income is nowhere near the 97.7th percentile, because incomes have a long right tail.
Source: A z-score is the distance from the mean measured in standard deviations: z = (x − μ) / σ, so a value 30 above a mean of 100 with a standard deviation of 15 stands exactly two deviations out
Questions people ask
- What counts as a high z-score?
- By convention anything beyond ±2 is unusual and beyond ±3 is rare, but those are habits rather than rules. In a normal distribution about 5 % of values fall outside ±1.96 and about 0.3 % outside ±3. What a large z-score does not tell you is that something is wrong, important, or worth acting on — in a data set of ten thousand values you should expect roughly 27 of them past ±3 with nothing unusual going on at all.
- What is the difference between the one-tailed and two-tailed figure?
- The one-tailed number is the share of the curve beyond your value in the direction it lies. The two-tailed number is the share at least that far from the mean in either direction, so it is exactly twice the one-tailed number. Which one you want depends on the question you asked before you saw the data: if you only ever cared about values being too high, one tail; if a surprise in either direction would have interested you, two. Picking the tail after seeing which gives the smaller number is how p-values get their bad reputation.
- Is the p-value the probability that my result is due to chance?
- No, and this is the misreading that does the most damage. The p-value is the probability of seeing a value at least this extreme if the distribution you assumed is the true one. It says nothing about the probability that your assumption is right, nothing about the probability that any particular explanation is true, and nothing about whether the difference is large enough to care about. A tiny p-value from a huge sample can sit on a difference too small to matter.
- Do I use the sample or the population standard deviation here?
- Strictly the population one. A z-score assumes you know the mean and standard deviation of the distribution rather than estimating them, which is why standardised tests — where the scale was fixed in advance from a large calibration sample — are the textbook case. If you are plugging in a mean and deviation computed from a small sample of your own, the score is fine as a description but the probabilities beside it are optimistic, and a t-based approach is the honest one.
- How are the probabilities computed, and how accurate are they?
- The normal distribution has no closed-form integral, so the curve has to be summed. This page uses the Taylor series published by George Marsaglia in the Journal of Statistical Software in 2004, which the article reports as accurate to an absolute error below 8 × 10⁻¹⁶, with the tail version used here holding 14 to 16 correct digits. The results are checked against the true values printed in that article and against the handbook table. Past a z of about 17 the tail is reported as zero, because by then it is smaller than 10⁻⁶⁰ and no longer means anything.
- Why does a standard deviation of zero give no answer?
- Because the formula divides by it. A standard deviation of zero means every observation is identical to the mean, so there is no scale on which to measure distance and no value that is any number of deviations away. That is a fact about the data rather than a failure of the calculation.
Related tools
Standard Deviation Calculator
Paste a list of numbers for the mean, variance and standard deviation — sample and population side by side, so the n − 1 you need is the one you get.
Confidence Interval Calculator
Turn a mean, a standard deviation and a sample size into a margin of error and an interval, with the Student t value the sample size actually calls for.
Percentage Calculator
Work out a percentage of a number, the result of adding or removing it, and the percentage change between two values — all at once.
Found a problem, or want more?
A number that disagrees with its source is a defect, not a rounding preference.
What did you enter, what did the tool show, and what did you expect instead? If you have a source that disagrees with ours, a link to it is the most useful thing you can send.
Opens your mail app with the page and tool already filled in.