VAR.P function
Returns the variance of an entire population: the average squared distance of each value from the mean.
Available in Excel 2010 and later, Microsoft 365, Excel for the web, Excel for Mac 2011 and later
Excel 2010 and laterWorks in Google Sheets
Syntax
VAR.P(number1, [number2], ...)| Argument | What it means | |
|---|---|---|
number1 | Required | A number, reference or range covering the whole population. |
number2, ... | Optional | Up to 254 more values. |
Returns: The population variance σ² (in squared units).
How VAR.P works
Variance measures spread. For each value Excel takes its distance from the mean, squares it (so negatives do not cancel positives and big deviations count more), and averages those squares. VAR.P divides by n, which is right when the data covers the whole population, every store, every employee, every month of the year in question.
Because the deviations are squared, variance is in squared units ("units²"), which is hard to interpret directly; the square root, STDEV.P, brings it back to the original units. Variance is still important because variances of independent quantities add up, which makes it the workhorse of risk and portfolio calculations. For samples use VAR.S. Text, logical values and empty cells in ranges are ignored.
Examples
1Variance of daily output for a full week
| A | B | C | D | |
|---|---|---|---|---|
| 1 | Day | Units | ||
| 2 | Mon | 52 | 9.6667 | |
| 3 | Tue | 48 | ||
| 4 | Wed | 55 | ||
| 5 | Thu | 50 | ||
| 6 | Fri | 45 | ||
| 7 | Sat | 50 |
Result: 9.6667
The mean is 50. The squared deviations average to 9.666667 (shown to 4 decimals), so the standard deviation is about 3.11 units.
2Check: variance is the squared standard deviation
| A | B | C | D | |
|---|---|---|---|---|
| 1 | Day | Units | ||
| 2 | Mon | 52 | 9.6667 | |
| 3 | Tue | 48 | ||
| 4 | Wed | 55 | ||
| 5 | Thu | 50 | ||
| 6 | Fri | 45 | ||
| 7 | Sat | 50 |
Result: 9.6667
Squaring STDEV.P returns the same 9.6667 (shown to 4 decimals), confirming the relationship.
Common errors and how to fix them
| Error | Why it happens | Fix |
|---|---|---|
#DIV/0! | No numbers in the arguments. | Check the range. |
#VALUE! | A typed argument is text that is not a number. | Use references. |
Tips
- VARP is the older name of the same function.
- Use VARPA if text and TRUE/FALSE should be counted as 0 and 1.
Google Sheets
VAR.P also exists in Google Sheets and works the same way for everyday use, so the examples above work there too.
VAR.P in other languages
In a non-English version of Excel the function has a local name. Excel translates formulas automatically when a file is opened in another language.
| Language | Function name |
|---|---|
| Danish | VARIANS.P |
| French | VAR.P.N |
| Hungarian | VAR.S |
| Norwegian (Bokmål) | VARIANS.P |
| Polish | WARIANCJA.POP |
| Russian | ДИСП.Г |
| Swedish | VARIANS.P |