Z-Score Calculator
Find how many standard deviations a value is from the mean. Enter a value, a mean, and a standard deviation below, and see the formula, a worked example, and ready-to-use Python code underneath.
Enter your values
Please fill in all three fields — standard deviation must be greater than 0.
What a z-score tells you
A z-score (or standard score) restates a raw value in terms of standard deviations from the mean, so values from different scales become directly comparable. A z-score of 1.5 means the value sits 1.5 standard deviations above the mean; a z-score of -0.8 means it sits 0.8 standard deviations below the mean.
If the underlying data is approximately normally distributed, a z-score also converts into a percentile — the share of the distribution that falls below that value — which is what makes z-scores useful for things like standardized test results or quality-control limits.
Z-score formula
Python code
You can compute a z-score directly, and convert it to a percentile using SciPy's normal distribution:
# z-score x, mean, std = 85, 75, 8 z = (x - mean) / std print(z) # 1.25 # percentile (requires SciPy) from scipy.stats import norm percentile = norm.cdf(z) * 100 print(percentile) # 89.44
Worked example
Suppose an exam has a mean score of 75 and a standard deviation of 8, and a student scores 85.
- 1Subtract the mean from the value.
85 − 75 = 10 - 2Divide by the standard deviation.
10 / 8 = 1.25
The student's z-score is 1.25 — their score is 1.25 standard deviations above the mean, which corresponds to roughly the 89th percentile if exam scores are approximately normally distributed.
Frequently asked questions
What does a z-score actually mean?
A z-score tells you how many standard deviations a value is from the mean. A z-score of 0 means the value equals the mean, a positive z-score means it's above the mean, and a negative z-score means it's below the mean.
What is a "good" z-score?
There's no universal good or bad z-score — it depends on what you're measuring and what direction is desirable. As a rule of thumb, z-scores between -2 and 2 are common, and values beyond about ±3 are unusual in a normal distribution.
How is the percentile calculated from a z-score?
The percentile is the cumulative probability of the standard normal distribution up to that z-score, often written as Φ(z). This calculator computes it using a standard numerical approximation of the normal cumulative distribution function.
Does the z-score formula require the data to be normally distributed?
The z-score itself (subtracting the mean and dividing by the standard deviation) can be computed for any distribution. However, the percentile interpretation, where a z-score of 1.96 corresponds to about the 97.5th percentile, assumes the underlying data is approximately normally distributed.
What is the difference between a z-score and a z-test?
A z-score standardizes a single value relative to a distribution. A z-test uses a similarly standardized statistic to test a hypothesis about a population mean using sample data, and produces a p-value used to make a decision.