Calculate standard deviation and variance
Paste a list of numbers and choose sample or population. Calculate standard deviation, variance, mean and count without uploading your data.
Calculations run in your browser. The values you enter are not uploaded or stored by this tool.
How it works
- Paste numbers separated by spaces, commas, semicolons or new lines. Use a decimal point and omit thousands separators.
- Choose Sample for an estimate from sampled observations, or Population for the complete population being described.
- Read standard deviation, variance, mean and count, then copy the results.
Sample and population use different divisors
The mean is the sum of the observations divided by their count n. Population variance divides the sum of squared deviations from that mean by n. Sample variance divides it by n − 1. Standard deviation is the square root of variance. For 2, 4, 4, 4, 5, 5, 7, 9 the mean is 5; population variance is 4 and population standard deviation is 2. The sample variance is 32/7 and sample standard deviation is about 2.1381.
How to enter a numeric list
Use 1.5 for a decimal, not 1,5. Commas are list separators, so 1,000 is interpreted as two observations, 1 and 0; enter 1000 for one thousand. Scientific notation such as 1e3 is accepted. Fractions, percentages, NaN and Infinity are rejected rather than silently omitted. Limits on characters and observations are shown beside the input and may be lower on low-memory devices.
Numerical accuracy and interpretation
The calculation uses an offset-centered Welford algorithm to reduce cancellation when observations are close together but large. It still uses floating-point numbers, so values beyond their representable precision cannot be recovered. Calculations that overflow, or underflow so that distinct observations would falsely appear to have zero variance, are rejected. Try expressing the values in a different consistent unit. Standard deviation has the same units as the observations; variance has squared units. Neither result alone proves normality or identifies an outlier.
Worked examples
| Numbers | Formula | Mean | Variance | Standard deviation |
|---|---|---|---|---|
| 2, 4, 4, 4, 5, 5, 7, 9 | Population (n) | 5 | 4 | 2 |
| 2, 4, 4, 4, 5, 5, 7, 9 | Sample (n − 1) | 5 | 4.5714 | 2.1381 |
| -2, 0, 2 | Sample (n − 1) | 0 | 4 | 2 |
| 5, 5, 5 | Population (n) | 5 | 0 | 0 |
Frequently asked questions
Should I choose sample or population?
Choose Population when describing every observation in the population of interest. Choose Sample when using sampled observations to estimate population variance. The sample calculation uses n − 1, so it requires at least two numbers.
Can I calculate standard deviation for one number?
Population standard deviation for one observation is zero. Sample standard deviation is undefined because the divisor n − 1 is zero; the calculator shows an explanation instead of a result.
What do repeated values do?
Every entered observation counts, including duplicates. Identical observations have zero variance and zero standard deviation.
Are negative numbers allowed?
Yes. For −2, 0 and 2 the mean is zero, sample variance is 4 and sample standard deviation is 2.
Sources
Last reviewed: October 18, 2026
Related tools
- Average CalculatorFind the average (mean), median, mode, sum and range of a list of numbers. Paste a column from a spreadsheet; it's free, instant and private.
- Percentage Error CalculatorCalculate percentage error from measured and reference values. See signed error, absolute error and the formula, including negative reference values.
- Fraction CalculatorAdd, subtract, multiply and divide fractions and mixed numbers, with the answer simplified, as a mixed number and as a decimal. Free.