KKwikfig.

Standard Deviation Calculator

Calculate population and sample standard deviation side by side, with the mean, squared deviations and variance shown step by step for your data set. Runs entirely in your browser — your numbers never leave this device.

Numbers
Data type
Population standard deviation (σ)
2
Mean x̄ = 5 · Variance = 4
Mean (x̄)
5
Variance
4
Standard deviation
2
Σ(x − x̄)²
32
How each value deviates from the mean
xx − x̄(x − x̄)²
2-39
4-11
4-11
4-11
500
500
724
9416

How it works

Population: σ = √( Σ(x − μ)² / N ) | Sample: s = √( Σ(x − x̄)² / (n − 1) ) | Variance is the value inside the root: σ² or s²

Standard deviation measures spread: how far values typically sit from their mean. The calculator finds the mean, subtracts it from every value to get the deviations, squares each deviation (so negatives do not cancel positives, and large gaps count for more), averages the squares to get the variance, then takes the square root to return to the original units. The full deviation table is shown so every step can be checked.

The one decision that matters is population versus sample. If your numbers are the entire group you care about — every student in one class, every day of one month — divide by N and you have the population standard deviation, σ. If your numbers are a sample used to estimate a bigger group, divide by n − 1 instead; this is called Bessel's correction, and it compensates for the fact that a sample usually sits a little closer to its own mean than the full population does. The sample value is therefore always the larger of the two.

A standard deviation of zero means every value is identical — there is no spread to measure. A single value has no meaningful standard deviation at all: the population formula returns 0 and the sample formula divides by n − 1 = 0, which is undefined, and the calculator says so plainly. Results are rounded to two decimal places in the headline, with more precision kept in the working.

Worked examples

The classic textbook set: 2, 4, 4, 4, 5, 5, 7, 9

Input
Values = 2, 4, 4, 4, 5, 5, 7, 9 (N = 8)
Working
Mean = (2+4+4+4+5+5+7+9) / 8 = 40 / 8 = 5. Value | Deviation (x − 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 Sum of squared deviations = 9+1+1+1+0+0+4+16 = 32. Population: variance = 32 / 8 = 4, σ = √4 = 2. Sample: variance = 32 / 7 ≈ 4.571, s = √4.571 ≈ 2.14.
Result
Population SD = 2 exactly, Sample SD ≈ 2.14

An evenly spaced set: 10, 12, 14, 16, 18

Input
Values = 10, 12, 14, 16, 18 (N = 5)
Working
Mean = 70 / 5 = 14. Deviations: −4, −2, 0, 2, 4. Squared: 16, 4, 0, 4, 16, summing to 40. Population: variance = 40 / 5 = 8, σ = √8 ≈ 2.83. Sample: variance = 40 / 4 = 10, s = √10 ≈ 3.16.
Result
Population SD ≈ 2.83, Sample SD ≈ 3.16

No spread at all: 7, 7, 7, 7

Input
Values = 7, 7, 7, 7 (N = 4)
Working
Mean = 28 / 4 = 7. Every deviation is 7 − 7 = 0, every squared deviation is 0, and the sum is 0. Variance = 0 / 4 = 0 for the population and 0 / 3 = 0 for the sample, so both standard deviations are √0 = 0.
Result
Population SD = 0, Sample SD = 0

Frequently asked questions

Should I use the population or sample standard deviation?

Use population (divide by N) when your data covers the whole group you are describing. Use sample (divide by n − 1) when your data is a sample drawn to estimate a larger population — survey responses, a batch tested from a production run, or measurements from some days out of a year. When in doubt, sample is the safer, more common choice in statistics.

Why does the sample formula divide by n − 1 instead of n?

A sample's deviations are measured from the sample's own mean, which is fitted to that sample, so the squared deviations come out slightly too small on average. Dividing by n − 1 instead of n inflates the result just enough to correct that bias — this is Bessel's correction, and it is why sample SD is always at least as large as population SD on the same data.

What is the difference between variance and standard deviation?

Variance is the average of the squared deviations; standard deviation is its square root. Squaring puts the units into squares as well (square dollars, square centimetres), which is hard to interpret, so the standard deviation is the number usually reported — it is in the same units as your original data.

Can standard deviation be negative?

No. It is the square root of an average of squares, and squares are never negative, so the smallest possible standard deviation is 0 — reached only when every value in the set is identical. A large SD means wide spread; it says nothing about whether values sit above or below the mean.

What does a standard deviation tell me in plain language?

Roughly, it is the typical distance between a value and the mean. For data that follows a bell curve, about 68% of values fall within one standard deviation of the mean and about 95% within two. A set with mean 5 and SD 2, like the worked example above, has most values clustered a couple of points either side of 5.

Is my data set uploaded when I calculate its standard deviation?

No. The calculation runs 100% in your browser — your numbers never leave your device, nothing is uploaded or stored, and no one can see the data you pasted. Close the tab and it is gone.

Related tools

More in Math Calculators · Browse all tools