01 / Deviation
Distance from the mean
Subtract the mean from each value, then square the result so every distance counts as positive.
Free tool
Paste your numbers to get the sample and population standard deviation and variance, the mean, the sum of squares, the standard error, the coefficient of variation and a z-score for every value. A table shows each step (value, deviation, squared deviation), a small plot shows where the numbers sit around the mean, and an optional confidence interval for the mean is there if you need one. Numbers can be split by spaces, commas, tabs or new lines, so a spreadsheet column pastes straight in.
Pick A sample when your numbers are only some of a bigger group, which is the usual case. Pick The whole group when you have every value.
Worked out in your browser. Nothing is sent anywhere.
The maths
01 / Deviation
Subtract the mean from each value, then square the result so every distance counts as positive.
02 / Variance
Add the squares and divide by n for a whole group, or by n − 1 for a sample.
03 / Standard deviation
The square root of the variance, so the spread is in the same units as your numbers.
Guide
A standard deviation calculator measures how spread out a list of numbers is. A small standard deviation means the numbers sit close to their mean. A large one means they are scattered. This page gives both versions, sample and population, side by side, together with the variance, mean, sum of squares, standard error, coefficient of variation and a z-score for each value. It writes out each step so you can check it against your homework or your spreadsheet.
The two versions differ in one divisor. The population standard deviation divides the sum of squares by n, the number of values. The sample standard deviation divides by n − 1. A sample tends to sit a little closer to its own mean than to the true mean of the whole group, so dividing by n would come out too small. Dividing by n − 1 corrects for that. Use the population version only when your list really is everything, such as the scores of every student in one small class. Use the sample version for survey answers, measurements and test results, which stand in for a larger group.
Take 2, 4, 4, 4, 5, 5, 7, 9. There are 8 numbers and they add up to 40, so the mean is 5. The distances from the mean are −3, −1, −1, −1, 0, 0, 2 and 4. Squared, they are 9, 1, 1, 1, 0, 0, 4 and 16, and these add up to 32. That is the sum of squares.
| Version | Variance | Standard deviation |
|---|---|---|
| Population (divide by 8) | 32 / 8 = 4 | 2 |
| Sample (divide by 7) | 32 / 7 = 4.5714 | 2.1381 |
The standard error of the mean is the sample standard deviation divided by the square root of n: 2.1381 / √8 = 0.7559. The coefficient of variation is the standard deviation divided by the mean, 2.1381 / 5 = 42.76%, which lets you compare spread between lists with different units or sizes. It is not defined when the mean is 0.
A z-score says how many standard deviations a value is from the mean: z = (value − mean) / standard deviation. In the example above the value 9 has a z-score of (9 − 5) / 2.1381 = 1.87 using the sample standard deviation, so it sits about 1.9 standard deviations above the mean. A value equal to the mean has a z-score of 0, and a negative z-score means the value is below the mean. The z-scores use whichever version you chose.
A confidence interval gives a range for the true mean of the group that your sample came from. It is the mean plus and minus a margin, and the margin is t times the standard error. The t value comes from Student's t distribution with n − 1 degrees of freedom. The page finds it by inverting that distribution in your browser, so any level and any size of list works. For the example, with 7 degrees of freedom and a 95% level, t is 2.3646, the margin is 2.3646 × 0.7559 = 1.7875, and the interval is 3.2125 to 6.7875. The method assumes your numbers are a random sample from a group that is roughly normal. With a few numbers, treat it as a rough guide.
For the mean, median and mode of the same list, use the average calculator. For the square roots and powers by hand, try the scientific calculator.
Questions
Find the mean, subtract it from each value, square those distances, add them up, divide by n (population) or n − 1 (sample), and take the square root.
The sample version divides by n − 1 and the population version divides by n. Use the sample version when your numbers are only part of a bigger group.
A sample sits closer to its own mean than to the true mean of the group, which makes the spread look too small. Dividing by n − 1 corrects for that.
There is no good or bad value on its own. It is in the same units as your numbers, so compare it with the mean, or use the coefficient of variation.
The number of standard deviations a value is above or below the mean. A z-score of 2 means two standard deviations above the mean.
The standard deviation squared. It is the sum of squares divided by n or n − 1. It is shown in the cards next to the standard deviation.
Yes. The sample version matches STDEV.S and the population version matches STDEV.P, apart from tiny rounding in the last digits.
No. It is a square root, so it is 0 or more. It is 0 only when every number is the same.
No. The numbers stay in your browser. They are only remembered on your own device so the page is ready next time.