SUMIFS Returning 0 (or the Wrong Total)? How to Fix SUMIFS, COUNTIFS and AVERAGEIFS
You need a total by customer and month, or a count of open invoices over $1,000, and SUMIFS returns 0, COUNTIFS gives a number that is obviously too low, or AVERAGEIFS shows #DIV/0!. These three functions share the same structure, so they also share the same failure points.
Get the syntax right first
=SUMIFS(sum_range, criteria_range1, criteria1, [criteria_range2, criteria2], ...)
=COUNTIFS(criteria_range1, criteria1, [criteria_range2, criteria2], ...)
=AVERAGEIFS(average_range, criteria_range1, criteria1, ...)
Note the order: in SUMIFS and AVERAGEIFS the range you add up comes first, the opposite of the older SUMIF. Mixing the two up is a classic cause of zero results.
Example: total sales for the East region in 2026 over $1,000:
=SUMIFS(Sales[Amount], Sales[Region], "East", Sales[Amount], ">1000", Sales[Date], ">="&DATE(2026,1,1))
Step-by-step fix
1. Numbers stored as text in the sum range
SUMIFS silently skips text, so a column of "numbers" imported from a bank file or accounting export can add up to 0. Check with =ISNUMBER(C2). Fix it by selecting the column, then Data → Text to Columns → Finish, or multiply by 1 in a helper column.
2. Criteria text doesn't match exactly
"East " (with a trailing space) or "East Region" will not match "East". Clean the criteria column with TRIM, or use a wildcard when partial matches are fine:
=SUMIFS(C:C, A:A, "*East*")
3. Operators and cell references written wrong
Comparison operators must be in quotes and joined to cell references with &. These are wrong: ">F1" and >F1. This is right:
=COUNTIFS(C:C, ">"&F1)
4. Date criteria don't match real dates
If the date column is text (common in CSV exports), date criteria never match. Confirm with ISNUMBER, convert with Text to Columns or DATEVALUE, and build criteria with DATE() rather than typed text:
=SUMIFS(C:C, B:B, ">="&DATE(2026,11,1), B:B, "<"&DATE(2026,12,1))
5. Ranges are different sizes
Every range in the formula must be the same height: C2:C500 with A2:A400 returns #VALUE!. Use whole columns, or better, format the data as a Table (Ctrl+T) and use structured references so ranges grow automatically.
6. Expecting OR logic
All criteria in SUMIFS and COUNTIFS are AND conditions. To count "East OR West", add two formulas together, or use an array constant:
=SUM(SUMIFS(C:C, A:A, {"East","West"}))
Bonus: AVERAGEIFS returns #DIV/0!
That means no rows met every condition, so check causes 1 to 5. If an empty result is legitimate, wrap it: =IFERROR(AVERAGEIFS(...), "No data").
Quick checklist
- Sum or average range comes first (SUMIFS, AVERAGEIFS)
- Sum range contains real numbers, not text
- Criteria text matches exactly (TRIM, or use wildcards)
- Operators in quotes, joined with &
- Dates are real dates, and criteria are built with DATE()
- All ranges are the same size (or use a Table)
Frequently asked questions
Usually the sum range contains numbers stored as text, the criteria do not match exactly because of spaces or spelling, or the arguments are in SUMIF order instead of SUMIFS order.
SUMIF takes one condition and puts the sum range last. SUMIFS takes one or more conditions and puts the sum range first. SUMIFS works for single conditions too, so it is the safer habit.
Not directly, because all conditions are AND. Add separate COUNTIFS together, or use SUM with an array constant like {"East","West"}.
Reference it directly for an exact match (A:A, F1), or join it to an operator with & for comparisons (">="&F1).
Yes, with the same syntax and the same fixes.