Skip to content

Standard Deviation Calculator

Paste your numbers to get the standard deviation and variance, for a sample or a whole population, plus a table that shows every step of the working.

Free, no sign-up · Last updated

commas, spaces or new lines
The numbers are

A part of a larger group. Divides by n − 1 (Bessel’s correction).

US defaults ·

Sample standard deviation (s)

2.13809

Mean
5
Sample variance (s²)
4.571429
Count (n)8
Sum of squared deviations32
Standard error of the mean0.755929
Coefficient of variation42.761799%

Use the sample formula when your numbers are a subset drawn from a bigger group (the usual case), and the population formula when you have every value. For roughly bell-shaped data, about 68% of values fall within one standard deviation of the mean and 95% within two.

Definition

What standard deviation measures

Standard deviation measures how spread out values are around their mean. It takes the square root of a variance based on squared distances from the mean, so the result has the same units as the original values.

Read in
The same units as your data
Entire population
Divide squared deviations by N
Sample estimate
Divide squared deviations by n − 1

What the number tells you

Two classes can both average 70% on a test yet be very different. In one, every pupil scored between 65% and 75%. In the other, scores ran from 30% to 100%. The averages match; the standard deviations are around 4 and 20, and the second class needs a very different kind of teaching.

Standard deviation is used to judge consistency, such as the quality of a manufacturing process, the risk of an investment’s returns and the reliability of a measurement.

A worked example

Take 2, 4, 4, 4, 5, 5, 7 and 9. The mean is 40 ÷ 8 = 5. The deviations from the mean are −3, −1, −1, −1, 0, 0, 2 and 4, and their squares are 9, 1, 1, 1, 0, 0, 4 and 16, which add up to 32. For a population, variance = 32 ÷ 8 = 4, so σ = 2. For a sample, variance = 32 ÷ 7 = 4.571, so s = 2.138. The standard error is 2.138 ÷ √8 = 0.756, and the coefficient of variation is 2 ÷ 5 = 40% (population).

Using it well

Choose sample or population honestly. Almost all real data are samples, so the sample formula is the safe default. Look out for outliers: because the deviations are squared, a single extreme value can inflate the standard deviation a lot. Check the working table to see which values contribute most.

For the centre of your data, use the average calculator.

A note on outliers and n − 1

Outliers have an outsized effect on standard deviation because the differences are squared. If one value is far from the rest, check it is not a typing error before you rely on the result, and consider reporting the median and the interquartile range as well.

The n − 1 divisor, Bessel’s correction, gives an unbiased estimate of the population variance from a sample. For large samples the difference between dividing by n and n − 1 is small, but for small samples it matters: with only 5 values it changes the answer by about 12%.

Step-by-step example

Calculate the spread of 2, 4, 4, 4, 5, 5, 7 and 9 as both a population and a sample.

StepResult
Mean5
Sum of squared deviations32
Population variance4
Population standard deviation2
Sample variance4.571
Sample standard deviation2.138
Standard error of the mean0.756

Formulas used

Population standard deviation (σ)

σ = √[ Σ (xᵢ − μ)² ÷ N ]

σ
population standard deviation
Σ
sum over all observations
xᵢ
one population value
μ
population mean
N
population size

Example: Data 2, 4, 4, 4, 5, 5, 7, 9: Σ(x − 5)² = 32, so σ = √(32 ÷ 8) = 2.

Sample standard deviation (s)

s = √[ Σ (xᵢ − x̄)² ÷ (n − 1) ]

s
sample standard deviation
Σ
sum over all observations
xᵢ
one sample value
x̄
sample mean
n
sample size

Example: s = √(32 ÷ 7) = 2.138.

Variance, standard error and coefficient of variation

Variance = standard deviation²

Standard error = s ÷ √n

CV = standard deviation ÷ mean × 100%

s
sample standard deviation
n
sample size
CV
coefficient of variation

Example: Standard error = 2.138 ÷ √8 = 0.756; CV (population) = 2 ÷ 5 = 40%.

When the answer can mislead

  • A single extreme value can raise the standard deviation sharply because each deviation is squared.
  • A sample with only one value has no sample standard deviation.
  • Use the standard error for uncertainty in an estimated mean and standard deviation for spread among observations.

Questions

What is standard deviation?

Standard deviation measures how spread out numbers are around their mean. A small value means the numbers cluster close to the average; a large value means they are widely scattered. It is in the same units as the data, which makes it easier to interpret than variance.

What is the difference between sample and population standard deviation?

Population standard deviation (σ) divides the sum of squared deviations by n and is used when you have every member of the group. Sample standard deviation (s) divides by n − 1 and is used when your numbers are a sample from a larger group. The n − 1 corrects the tendency of a sample to underestimate spread. When unsure, use the sample version.

How do I calculate standard deviation step by step?

Find the mean. Subtract the mean from each value and square the result. Add the squares. Divide by n (population) or n − 1 (sample) to get the variance. Take the square root for the standard deviation. The working table under the result shows each step for your numbers.

What is variance?

Variance is the standard deviation squared: the average of the squared deviations from the mean. It is used in many statistical formulas, but because it is in squared units (for example square metres or dollars squared), the standard deviation is usually easier to read.

What does the 68-95-99.7 rule mean?

For data that follows a bell-shaped (normal) distribution, about 68% of values fall within one standard deviation of the mean, 95% within two and 99.7% within three. It does not hold for strongly skewed data.

What are the standard error and coefficient of variation?

The standard error of the mean is the sample standard deviation divided by the square root of n; it shows how precisely the sample mean estimates the true mean. The coefficient of variation is the standard deviation as a percentage of the mean, which lets you compare spread between data sets with different units or sizes.

Sources

  1. OpenStax: Sample and population standard deviation
  2. NIST: Coefficient of variation and relative standard deviation
Last updated How we check
Embed this calculator
Cite this calculator

Standard Deviation Calculator. CalculatorLab. https://calculatorlab.site/calculators/standard-deviation-calculator/. Last updated .