Free AVERAGEIFS practice
AVERAGEIFS practice exercises
AVERAGEIFS averages the values in one range for the rows that meet one or more conditions. 5 reps, from easy to hard, each checked in a real spreadsheet engine. 2 free, 3 with Pro.
=AVERAGEIFS(average_range, criteria_range1, criteria1, ...)
AVERAGEIFS guide
How to use AVERAGEIFS in Excel
AVERAGEIFS averages the numbers in one column for the rows that meet your conditions: the average sale in the South, the average score for one class. It works like SUMIFS, with the column to average first and then the conditions.
If no row meets the conditions, there is nothing to average and AVERAGEIFS returns #DIV/0!, so it's often wrapped in IFERROR.
Syntax
=AVERAGEIFS(average_range, criteria_range1, criteria1, ...)
| Argument | What it is |
|---|---|
average_range | The numbers to average, such as D2:D7. |
criteria_range1 | The column to check for the first condition, with the same number of rows as average_range. |
criteria1 | What that column must match: text in quotes, a cell, or a comparison such as ">=4". |
... | More range and criteria pairs. Only rows that meet all of them are averaged. |
Examples
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | Region | Product | Units | Sales | South average | |
| 2 | North | Widget | 4 | 200 | 225 | |
| 3 | South | Gadget | 2 | 150 | ||
| 4 | North | Gadget | 5 | 375 | ||
| 5 | East | Widget | 3 | 150 | ||
| 6 | North | Widget | 1 | 50 | ||
| 7 | South | Widget | 6 | 300 |
=AVERAGEIFS(D2:D7,A2:A7,"South") returns 225.
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | Region | Product | Units | Sales | North widgets | |
| 2 | North | Widget | 4 | 200 | 125 | |
| 3 | South | Gadget | 2 | 150 | ||
| 4 | North | Gadget | 5 | 375 | ||
| 5 | East | Widget | 3 | 150 | ||
| 6 | North | Widget | 1 | 50 | ||
| 7 | South | Widget | 6 | 300 |
=AVERAGEIFS(D2:D7,A2:A7,"North",B2:B7,"Widget") returns 125.
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | Region | Product | Units | Sales | North average | |
| 2 | North | Widget | 4 | 200 | 208 | |
| 3 | South | Gadget | 2 | 150 | ||
| 4 | North | Gadget | 5 | 375 | ||
| 5 | East | Widget | 3 | 150 | ||
| 6 | North | Widget | 1 | 50 | ||
| 7 | South | Widget | 6 | 300 |
=ROUND(AVERAGEIFS(D2:D7,A2:A7,"North"),0) returns 208.
Common mistakes
No rows match
There are no West orders, so there is nothing to average and you get a divide-by-zero error. Wrap the formula in IFERROR to show 0 (or a message) instead.
Wrong=AVERAGEIFS(D2:D7,A2:A7,"West") → #DIV/0!
Right=IFERROR(AVERAGEIFS(D2:D7,A2:A7,"West"),0) → 0
Averaging the wrong column
The first argument is the column to average. Pointing it at Units averages the units, not the sales.
Wrong=AVERAGEIFS(C2:C7,A2:A7,"South") → 4
Right=AVERAGEIFS(D2:D7,A2:A7,"South") → 225
AVERAGEIFS questions
What is the difference between AVERAGEIF and AVERAGEIFS?
AVERAGEIF takes one condition and puts the range to average last. AVERAGEIFS takes one or more and puts it first. AVERAGEIFS covers both cases.
Why does AVERAGEIFS return #DIV/0!?
No row met all the conditions, so there was nothing to average. Check the criteria for typos and extra spaces, or wrap it in IFERROR.
Does AVERAGEIFS count blank cells?
No. Empty cells in the average range are skipped. Cells containing 0 are included.
Related functions
Reading is the warm-up
The reps are what make it stick. Try AVERAGEIFS in the practice sheet above.