Standard Deviation Calculator
Type or paste a list of numbers, choose whether they are a sample or a whole population, and see the standard deviation, variance, mean, count, range and more. A table shows each value, its distance from the mean and the square of that distance, so you can follow the working. Everything runs in your browser.
Working, step by step
| Value | Value minus mean | Squared |
|---|---|---|
| 2 | -3 | 9 |
| 4 | -1 | 1 |
| 4 | -1 | 1 |
| 4 | -1 | 1 |
| 5 | 0 | 0 |
| 5 | 0 | 0 |
| 7 | 2 | 4 |
| 9 | 4 | 16 |
Variance is the sum of squares divided by n - 1 (7), and the standard deviation is its square root.
Use the sample option when your numbers are a subset of a larger group, which is the usual case, and the population option when they are every value in the group. The mean, sums and variance are worked out exactly and rounded only when shown. Numbers are separated by commas, spaces, semicolons or new lines, so type 1200, not 1,200.
Related Tools
[4 suggestions]Mean, Median and Mode Calculator
Find the mean, median, mode, range, quartiles, variance and standard deviation of a list of numbers, with exact decimal arithmetic.
Math & MoneyPercentage Calculator
Find a percentage of a number, what percent one number is of another, a percentage increase or decrease, or a number raised or lowered by a percentage.
Math & MoneyFraction Calculator
Add, subtract, multiply and divide fractions, mixed numbers and decimals, simplify to lowest terms and see the steps.
Math & MoneyRandom Number Generator
Pick random numbers between any minimum and maximum, with decimals, no repeats and sorting. Every value is equally likely.
Writing & ContentAbout the Standard Deviation Calculator
The standard deviation measures how spread out numbers are around their mean. To work it out, find the mean, subtract it from each number, square each difference, add the squares, divide by n for a population or n minus 1 for a sample, and take the square root. For 2, 4, 4, 4, 5, 5, 7, 9 the mean is 5 and the squared differences add up to 32. As a whole population the variance is 32 divided by 8, which is 4, so the standard deviation is 2. As a sample it is 32 divided by 7, which is 4.571429, so the standard deviation is 2.138090. Use the sample version when your numbers are a subset of a larger group, which is the usual case, and the population version when you have every value. The tool also shows the standard error of the mean and the coefficient of variation. The mean and the sums of squares are worked out with exact integer arithmetic, so there is no floating point error, and only the final figures are rounded to the number of decimals you choose. We compared the mean, variance and standard deviation with Python's exact Fraction and Decimal types on 1,500 random lists, and they matched every time. Separate numbers with commas, spaces or new lines. The tool takes up to 5,000 numbers. Nothing is uploaded.
How do I calculate standard deviation?▾
Find the mean, subtract it from each value, square each difference, add the squares, divide by n for a population or n minus 1 for a sample, and take the square root. For 2, 4, 4, 4, 5, 5, 7, 9 the squares add up to 32, the population variance is 4 and the standard deviation is 2.
What is the difference between sample and population standard deviation?▾
The population version divides by n and is for data that includes every member of the group. The sample version divides by n minus 1 and is for a subset, which corrects for the sample's tendency to underestimate the spread. The sample result is a little larger.
What is the difference between variance and standard deviation?▾
Variance is the average squared distance from the mean, and the standard deviation is its square root. The standard deviation is in the same units as your data, which makes it easier to read. For 2, 4, 4, 4, 5, 5, 7, 9 the variance is 4 and the standard deviation is 2.
Can I enter decimals and negative numbers?▾
Yes. Use plain decimals such as 1.5 or -3.25. Separate numbers with commas, spaces, semicolons or new lines, and write 1200 rather than 1,200, because a comma separates numbers.
How accurate is the result?▾
The mean, the sum of squares and the variance are worked out exactly with integer arithmetic, so there is no floating point error. Only the final values are rounded, to the number of decimals you choose. We compared 1,500 random lists with Python's exact types and found no differences.