Standard Deviation Calculator

Sample and population standard deviation and variance.

Loading calculator…

Standard deviation tells you how spread out a set of numbers is. Paste your data into this standard deviation calculator, choose whether it is a sample or a whole population, and you get the standard deviation, the variance, the mean and the standard error. A table shows each value’s distance from the mean, so you can see where the answer comes from.

Quick answer: to find the standard deviation, work out the mean, subtract it from each value and square the result, add those squares, divide by n − 1 for a sample (or N for a whole population), then take the square root. For 2, 4, 4, 4, 5, 5, 7, 9, the population standard deviation is 2.

How to Use the Standard Deviation Calculator

  1. Paste or type your data set, separated by commas, spaces or new lines.
  2. Choose Sample (n − 1) or Whole population (N).
  3. Read the standard deviation, variance, mean, count, standard error of the mean, and the other type of standard deviation for comparison.

Sample or Population?

UseWhenDivide by
PopulationYour data includes every member of the group, such as all 30 students in one classN
SampleYour data is part of a bigger group and you want to describe the whole group, such as 100 voters out of a cityn − 1

If you are not sure, choose sample. Most real-world data is a sample. Dividing by n − 1 (called Bessel’s correction) slightly increases the result to make up for the fact that a sample tends to underestimate the spread of the full group.

Standard Deviation Formulas

  • Population: σ = √( Σ(x − μ)² ÷ N )
  • Sample: s = √( Σ(x − x̄)² ÷ (n − 1) )
  • Variance is the same calculation without the square root: σ² or s².

Worked Example

Data: 2, 4, 4, 4, 5, 5, 7, 9 (8 values)

  1. Mean: 40 ÷ 8 = 5
  2. Deviations from the mean: −3, −1, −1, −1, 0, 0, 2, 4
  3. Squared: 9, 1, 1, 1, 0, 0, 4, 16
  4. Sum of squares: 32
  5. Population variance: 32 ÷ 8 = 4, so population SD = 2
  6. Sample variance: 32 ÷ 7 ≈ 4.571, so sample SD ≈ 2.138

The standard error of the mean (sample SD ÷ √n) is about 0.756.

What Standard Deviation Tells You

  • Small standard deviation: values are close to the mean. Test scores of 78, 79, 80, 81, 82 are tightly grouped.
  • Large standard deviation: values are spread out. Scores of 50, 65, 80, 95, 100 vary a lot, even with a similar mean.

For data that follows a normal (bell-shaped) distribution:

RangeShare of values
Within 1 standard deviation of the meanAbout 68%
Within 2 standard deviationsAbout 95%
Within 3 standard deviationsAbout 99.7%

So if exam scores have a mean of 70 and a standard deviation of 10, about 95% of students scored between 50 and 90.

Mistakes to Avoid

  • Choosing population for a sample. It makes the spread look smaller than it really is.
  • Confusing variance and standard deviation. Variance is in squared units. The standard deviation is in the same units as your data, which makes it easier to interpret.
  • Comparing spreads of very different sizes. A standard deviation of 5 is large for values around 10, but small for values around 1,000.

For the mean, median, mode and range of the same data, use the average calculator.

Standard Deviation FAQs

Can standard deviation be negative?

No. It is a square root of a sum of squares, so it is always 0 or more. It is 0 only when every value is the same.

What is the difference between standard deviation and variance?

Variance is the average squared distance from the mean. Standard deviation is the square root of the variance, which puts it back into the same units as the data.

What is the standard error of the mean?

It estimates how much the mean of a sample would vary if you took many samples. It equals the standard deviation divided by the square root of the number of values.

How many numbers do I need?

At least two. With very few values, the result is not a reliable picture of the wider group.

How we checked this page: the worked example was calculated by hand for both sample and population, and matches the calculator.

Scroll to Top