Standard Deviation & Variance Calculator

Calculate both population and sample standard deviation and variance from a list of numbers — enter your data and every value updates live.

Enter at least two numbers, separated by commas, spaces, semicolons, or new lines. Negative, decimal, and scientific notation values are supported.
Result Live
Population
Variance
Std. Deviation
Sample
Variance
Std. Deviation

Population vs. sample: which one do you need?

This is the single most common point of confusion with this calculation, and getting it wrong changes the answer. Use population statistics when your data is the entire group you care about — every student in a class, every day in a specific month. Use sample statistics when your data is a subset drawn from a larger group you're trying to draw conclusions about — a survey of 200 people meant to represent a much larger population. Sample variance divides by one less than the count (N−1, "Bessel's correction") specifically because a sample's own variance tends to slightly underestimate the true population variance; dividing by a smaller number corrects for that bias. When genuinely unsure, sample statistics are the more common and more conservative default.

Formulas

Population Variance
σ² = Σ(x − μ)² ÷ N
Sample Variance
s² = Σ(x − x̄)² ÷ (N − 1)

Standard deviation is just the square root of variance, in both cases — whichever variance you compute, square-rooting it converts the result back into the same units as the original data, which is why standard deviation is usually the more intuitive number to report even though variance is the one calculated first.

Worked example

For the data set 2, 4, 4, 4, 5, 5, 7, 9 (mean = 5): the squared deviations from the mean sum to 32. Dividing by the count (8) gives a population variance of 4, and a population standard deviation of 2. Dividing instead by one less than the count (7) gives a sample variance of about 4.571, and a sample standard deviation of about 2.138.

Frequently asked questions

What's the difference between population and sample standard deviation?

Population standard deviation treats your data as the complete group of interest and divides by the count (N). Sample standard deviation treats your data as a subset representing a larger group and divides by one less than the count (N-1), which corrects for the tendency of a sample to slightly underestimate the true population variance.

How do you calculate standard deviation?

Find the mean, calculate each value's squared difference from the mean, sum those squared differences, divide by the count (population) or count minus one (sample), then take the square root of the result.

Why does sample variance divide by N-1 instead of N?

Because a sample's own mean is calculated from the same data being measured, the sample's squared deviations tend to run slightly smaller than the true population's would. Dividing by N-1 instead of N (Bessel's correction) counteracts that bias, giving a more accurate estimate of the population's actual variance.