Skip to content

Standard Deviation Calculator

Find the sample or population standard deviation, variance, mean and standard error of a list of numbers, with a table of every deviation from the mean.

  • Free, no sign-up
  • Runs in your browser
  • Math
Data set
Separate numbers with commas, spaces or new lines, for example: 2, 4, 4, 4, 5, 5, 7, 9. Up to 10,000 numbers. Do not use thousands separators.

How to use the calculator

Choose Sample or Population, paste or type your numbers separated by commas, spaces or new lines, and press Calculate. You can enter up to 10,000 numbers. Do not use thousands separators, because a comma starts a new number.

The result shows the standard deviation, the variance, the mean, the count, the sum and the standard error of the mean. The details table lists every value with its deviation from the mean and the squared deviation, plus a sum row.

Sample or population?

Use Population when your list contains every member of the group you care about, for example the scores of all 25 students in one class. Use Sample when your list is a subset that stands in for a larger group, for example 25 students picked from a whole school. Sample is the default because most real data is a sample.

The only difference is the divisor. The population variance divides the sum of squared deviations by n. The sample variance divides it by n − 1, which corrects the tendency of a sample to underestimate the spread of the full group. A sample needs at least 2 numbers.

The formula

  1. Find the mean: add the values and divide by the count.
  2. Subtract the mean from each value to get its deviation.
  3. Square each deviation and add the squares.
  4. Divide by n (population) or n − 1 (sample) to get the variance.
  5. Take the square root of the variance to get the standard deviation.

The standard error of the mean is the sample standard deviation divided by the square root of n. It estimates how far the sample mean is likely to be from the true mean of the whole group.

Worked example

Take the values 2, 4, 4, 4, 5, 5, 7 and 9.

  • The sum is 40 and the count is 8, so the mean is 5.
  • The deviations are -3, -1, -1, -1, 0, 0, 2 and 4.
  • The squared deviations are 9, 1, 1, 1, 0, 0, 4 and 16, which add up to 32.
  • Population: variance = 32 ÷ 8 = 4, standard deviation = 2.
  • Sample: variance = 32 ÷ 7 ≈ 4.571428571, standard deviation ≈ 2.138089935.
  • Standard error of the mean ≈ 2.138089935 ÷ √8 ≈ 0.755928946.

Good to know

  • The standard deviation is in the same unit as your data; the variance is in that unit squared.
  • A standard deviation of 0 means every value is the same.
  • The deviations from the mean always add up to 0, which is a quick way to check the table.
  • The calculator first finds the mean and then sums the squared deviations, with a small correction step. This two-pass method stays accurate even when the values are very large and close together, where the shortcut formula with the sum of squares can lose all precision.

Frequently asked questions

What is the difference between sample and population standard deviation?

The population standard deviation divides the sum of squared deviations by the number of values, n. The sample standard deviation divides by n − 1. Use population when your data covers the whole group and sample when it is only part of a larger group. The sample result is always a little larger.

Why does a sample need at least two numbers?

The sample formula divides by n − 1. With a single value that is a division by zero, and one value says nothing about how spread out the larger group is. For a single value, choose Population, which gives a standard deviation of 0.

What does the standard error of the mean tell me?

It estimates how much the mean of a sample would vary if you took many samples of the same size. It equals the sample standard deviation divided by the square root of the count, so it shrinks as the sample grows. The calculator always uses the sample standard deviation for it.

How are variance and standard deviation related?

The standard deviation is the square root of the variance. The variance is useful in further calculations, while the standard deviation is easier to read because it uses the same unit as the data.