Skip to calculator
VarianceCalc

Variance, worked out step by step

Paste any data set — messy spreadsheet columns included. Get sample or population variance, standard deviation, and the mean, with every step shown on your real numbers.

Variance calculator

Try an example
Which variance?

Enter a data set and your results appear here instantly — no button to press.

Sample or population? The choice that trips people up

Both measure how spread out your numbers are. The only difference is what you divide by — and picking the wrong one is the most common variance mistake. Here’s how to decide in one glance.

s²

Sample variance

Your data is a subset of a bigger group you want to understand. Divides by n − 1 so it doesn’t underestimate the real spread.

s² = Σ(x − x̄)² / (n − 1)

Surveys, experiments, a batch of readings, test scores from some students — use this whenever your numbers are a sample drawn from a larger population you want to draw conclusions about.

σ²

Population variance

Your data is the entire group, with nothing left out. Divides by n — the exact spread of that complete set.

σ² = Σ(x − μ)² / n

Every employee in one company, all games in a season, a full census — cases where there’s no larger group to infer.

Same data, both ways: sample variance is always a little larger than population variance, because dividing by the smaller number (n − 1) makes the result bigger. That gap shrinks as your data set grows.

Questions, answered

Should I use sample or population variance?

Use sample variance (÷ n − 1) when your numbers are a sample drawn from a larger group you want to learn about — survey responses, a batch of measurements, test results from some students. Use population variance (÷ n) only when your numbers are the entire group, with nothing left out. When unsure, sample is the safer default; picking population on sample data slightly understates the real spread.

Why does sample variance divide by n − 1 instead of n?

It’s called Bessel’s correction. Because the mean is estimated from the same sample, dividing by n would systematically underestimate the true spread. Dividing by n − 1 (the degrees of freedom) corrects that bias, giving an unbiased estimate of the population variance.

What’s the difference between variance and standard deviation?

Standard deviation is just the square root of variance. Variance is in squared units (dollars², cm²), which is hard to picture; standard deviation is back in the original units, so it’s easier to interpret. We show both.

How should I format my data?

However you have it. Paste straight from a spreadsheet, a document, or type it by hand — values can be separated by commas, spaces, tabs, or line breaks. Decimals and negative numbers work, and stray currency or percent symbols are ignored automatically.

Why is sample variance undefined for a single value?

Sample variance divides by n − 1. With one data point that denominator is 0, and dividing by zero is undefined. Add another value, or switch to population variance — which divides by n and is 0 for a single point.

Is my data sent anywhere?

No. Every calculation runs entirely in your browser — nothing you type is uploaded, logged, or stored. Your dataset is only ever placed into a URL if you explicitly click “Copy link” to share it; typing or pasting data never changes the address bar on its own.

What is the difference between sample and population variance?

The difference is what you divide the sum of squared deviations by. Sample variance divides by n − 1 and is used when your data is a subset drawn from a larger group you want to draw conclusions about. Population variance divides by n and is used only when your data is the entire group, with nothing left out. Sample variance is always slightly larger for the same numbers, since dividing by a smaller number produces a bigger result — that gap narrows as the data set grows.

Why do I get an error with only one data point?

Sample variance divides by n − 1, and with a single value that denominator becomes 0 — division by zero is mathematically undefined, so there's no valid result to show. This calculator explains that instead of returning NaN. If you need a result for one data point, switch to population variance, which divides by n and correctly returns 0, since a single value has no spread from itself.

What symbol represents variance?

Population variance is written as σ² (lowercase sigma squared), and sample variance is written as s². Both are read as “variance” — the squared symbol is a reminder that variance is measured in squared units of the original data (for example, dollars² or cm²), which is why standard deviation, its square root, is often used alongside it for easier interpretation.

Does this calculator show the steps for calculating variance?

Yes. Every result includes the full worked solution using your actual numbers — the mean, each value's deviation from the mean, the squared deviations, their sum, and the final division by n or n − 1. A deviation number-line also visualizes how far each value sits from the mean, so you can verify the answer and understand how it was reached rather than just seeing a final number.

Can I calculate variance from grouped or frequency data?

Not directly — this calculator expects a list of individual raw values, not a frequency table of value/count pairs. To use it with grouped data, expand each value by its frequency before pasting (for example, a value of 5 occurring 3 times becomes 5, 5, 5 in the input). For large frequency tables this gets impractical, since grouped variance is typically computed from midpoints and frequencies with a dedicated formula rather than raw values.

About this variance calculator

VarianceCalc is a free variance calculator online built for anyone who needs a fast, accurate answer without wrestling with a spreadsheet formula or a scientific calculator's manual mode. Paste in a list of numbers — copied straight from Excel, Google Sheets, a PDF report, or typed by hand — and the tool instantly returns variance, standard deviation, mean, count, and sum of squares, with the underlying math shown step by step using your own numbers. There's no sign-up, no installation, and no data ever leaves your browser: every calculation runs client-side, so it's safe to use with sensitive or proprietary figures.

What sets this variance calculator apart from a generic statistics widget is that it treats the sample-versus-population decision as a first-class feature rather than an afterthought. Flip the toggle to use it as a sample variance calculator, dividing by n − 1 (Bessel's correction) for datasets that represent a subset of a larger group you're trying to draw conclusions about — think survey responses, a batch of lab measurements, or grades from one class you want to generalize from. Or switch it into a population variance calculator, dividing by n, when your numbers are the complete set with nothing left out, like every employee at a company or every game in a finished season. Picking the wrong mode is the single most common variance mistake, so the calculator surfaces plain-language guidance right next to the toggle instead of leaving you to guess.

Under the hood, the parser is built to survive real-world, messy input rather than the clean, comma-separated lists most textbook tools expect. Values can be separated by commas, spaces, tabs, semicolons, or line breaks in any combination, and the calculator correctly handles decimals, negative numbers, and scientific notation. Because commas are always treated as separators, a pasted number like91,100 is read as two values — 91 and 100 — never silently merged into ninety-one thousand one hundred, which is a subtle bug that trips up simpler tools. Stray currency symbols ($) and percent signs (%) are stripped automatically, and any token that still can't be read as a number is reported clearly instead of being dropped without explanation.

Beyond the headline number, this variance calculator is built to teach as much as it computes. Every result comes with the full formula worked out using your actual data — the deviations from the mean, the squared deviations, and the final division — so you can follow exactly how the answer was reached and check it against your own work. A deviation number-line visualizes how far each individual value sits from the mean, which makes the concept of "spread" concrete rather than abstract, especially useful for students learning variance and standard deviation for the first time. Edge cases are handled gracefully too: a single-value sample returns a clear explanation instead of a confusing NaN, and empty or non-numeric input produces a helpful message rather than a silent failure.

The whole experience is designed to stay out of your way — no ads, no tracking scripts, and no forced account creation. If you want to share a specific result, an explicit "Copy link" action encodes your dataset and mode into the URL; nothing is written to the address bar just from typing or pasting. Whether you're a student checking homework, a researcher doing a quick sanity check, or an analyst who just needs variance and standard deviation without opening a full statistics package, this calculator is built to get you a trustworthy, explained answer in seconds.