Standard Deviation Calculator

Find how spread out a data set is. Choose population or sample, enter your numbers, and see every step from mean to square root.

Separate numbers with commas, spaces, or line breaks

Sample divides by n−1; population divides by n.
Advertisement

How to use this calculator

Enter your data, tell the calculator whether it is a population (every value that exists) or a sample (a subset), and press Calculate. You get the standard deviation, the variance, and the mean, with the deviation table worked out step by step.

How it works

Standard deviation measures spread: the typical distance of values from the mean. The recipe is: find the mean, subtract it from each value, square each difference, average the squares (this is the variance), then take the square root. Squaring first stops positive and negative deviations from cancelling out.

The one subtlety: a sample divides by n−1 instead of n (Bessel’s correction), because a sample tends to underestimate the true spread.

σ = √( Σ(x − μ)² ÷ n )  ·  s = √( Σ(x − x̄)² ÷ (n−1) )

Worked example

Example: 2, 4, 4, 4, 5, 5, 7, 9 (population)

Step 1, Mean: sum = 40, n = 8, mean = 5.

Step 2, Squared deviations: 9, 1, 1, 1, 0, 0, 4, 16 → sum = 32.

Step 3, Variance: 32 ÷ 8 = 4.

Step 4, SD: √4 = 2. A typical value sits about 2 away from the mean of 5.

Common mistakes

  • Population vs sample mix-up: using n instead of n−1 (or vice versa) is the #1 SD error. Ask: “do I have all the data, or just some of it?”
  • Forgetting the final square root: stopping at the variance (4) instead of the SD (2), variance is in squared units, SD is in the original units.
  • SD of a single value: one data point has no spread to measure. Sample SD needs at least 2 values; the calculator says so instead of dividing by zero.

When to use it

Standard deviation is the universal language of variability: test-score consistency, manufacturing tolerances, investment risk (volatility), poll margins of error, and quality control. A small SD means predictable; a large SD means wild.

Not sure whether to divide by n or n−1? Read population vs sample: the n vs n−1 decision.

Frequently asked questions

How far values typically stray from the average. An SD of 2 on a mean of 5 means for approximately bell-shaped data, about 68% of values fall within one standard deviation of the mean, roughly between 3 and 7 here. Larger SD = more spread.

Population (÷n) when your data includes every member of the group. Sample (÷(n−1)) when your data is a subset meant to estimate the whole, e.g. 50 survey respondents representing a city.

Raw deviations always sum to zero (positives cancel negatives), so their plain average is useless. Squaring makes everything positive; the square root at the end restores the original units.

For bell-shaped data, about 68% of values fall within 1 SD of the mean, 95% within 2 SD, and 99.7% within 3 SD. It turns an SD into an instant intuition about the data.

Standard deviation calculator with steps

Our standard deviation calculator shows the full working: mean, squared deviations, variance, and the final square root, for both sample and population formulas.

More statistics questions

Population standard deviation divides by N (every value counts); sample standard deviation divides by n – 1, which corrects the bias from estimating the mean from the sample itself. Use population when you have all the data, sample when your data is a subset.

Variance is the square of the standard deviation. If the standard deviation is 2, the variance is 4. It measures spread in squared units, which is why we take the square root to get back to the original units.