Standard Deviation Calculator

Calculate mean, median, mode, variance and standard deviation for any dataset. Shows step-by-step working and visual distribution

Enter numbers to calculate statistics

How to Use the Standard Deviation Calculator

Paste your dataset into the input box. The calculator accepts numbers separated by commas, spaces, or new lines (so you can drop a column straight from a spreadsheet without reformatting). It works out the count, mean, median, mode, range, variance and standard deviation, and shows where the data sits within one, two and three standard deviations of the mean.

Pick population or sample mode at the top. Population uses divisor n; sample uses divisor n-1 (Bessel's correction). The difference matters for small datasets and almost vanishes for large ones. Most real-world statistics, including pretty much every survey, every controlled experiment, and every test from a class of pupils, are samples drawn from a wider population, so sample standard deviation is the safer default unless you genuinely have every value in the population.

What Standard Deviation Actually Measures

Standard deviation tells you how spread out a set of numbers is around the mean. A small standard deviation means most values are clustered tightly around the average; a large one means they're scattered widely. Two datasets can share the same mean and look completely different in shape. Class A scoring 70, 70, 70, 70, 70 has a mean of 70 and a standard deviation of 0. Class B scoring 40, 55, 70, 85, 100 also has a mean of 70 but a standard deviation of about 23. The mean alone hides this entirely.

The formula is sqrt(sum((x - mean)^2) / n) for population, or sqrt(sum((x - mean)^2) / (n-1)) for sample. You square the deviations to make negatives positive (otherwise they'd cancel), average them to get variance, then square-root to bring the units back to the original scale. The 68-95-99.7 rule says that for a normal distribution, roughly 68% of values fall within 1 SD of the mean, 95% within 2 SDs, and 99.7% within 3 SDs.

Worked Example: Test Scores

ScoreDifference from meanSquared difference
62-864
68-24
7000
72+24
78+864
Mean = 70Sum = 0Sum = 136
Population SD = sqrt(136/5) = 5.22Sample SD = sqrt(136/4) = 5.83

When You'd Want to Know the Standard Deviation

Comparing consistency. Two football pundits make scoring predictions; whichever has the lower SD between predicted and actual scores is more reliable, even if their averages are similar. Quality control. A factory wants its product weights to cluster tightly around the target; rising SD signals a problem on the line before any single weight goes badly wrong. Investment risk. Standard deviation of monthly returns is the textbook definition of volatility; a fund with low SD is steady, a fund with high SD swings.

It's also the basis of z-scores, where a value is reported as 'X standard deviations above or below the mean'. A z-score of 0 is exactly average; a score of +2 means well above average (about top 2.5% if the data is normally distributed); a score of -3 means very far below. For more on combinations, sequences and core statistics, see the [Probability Calculator](/probability-calculator).

Frequently Asked Questions

Should I use population or sample standard deviation?

Use sample SD (divide by n-1) when your data is a sample from a larger population, which is almost always the case in social science, business analytics, opinion polls and class results. Use population SD (divide by n) only when you have literally measured every member of the population, like every employee at a small company on a specific day.

Why divide by n-1 for sample standard deviation?

It's called Bessel's correction. When you calculate variance from a sample, the sample mean is itself an estimate (not the true population mean), and using it slightly underestimates the true variance. Dividing by n-1 instead of n inflates the answer just enough to remove the bias. The effect is large for small samples (10 vs 9 changes the result by 10%) and tiny for large samples (1000 vs 999 changes it by 0.1%).

What does a standard deviation of zero mean?

Every value in the dataset is identical. This is rare with real measurements (there's almost always some noise) but common with categorical data converted to numbers, or in trivial test cases. A near-zero SD on real measurements suggests either extraordinary precision or that you've accidentally put the same value in every row.

What units is the standard deviation in?

The same units as your data. Heights in centimetres give an SD in centimetres; temperatures in Celsius give an SD in Celsius. This is why we square-root the variance: variance is in 'units squared' (centimetres squared, hard to visualise), and the square root brings it back to the original scale.

How many decimal places should I report?

One more than your raw data. If your measurements were to the nearest whole number, report SD to one decimal place. If they were to one decimal place, report to two. The calculator shows four decimal places so you can round as appropriate.

More tools β†’