Function Problems

WPS Spreadsheet: Use AVERAGEIFS Without Zeros or #DIV/0! Errors

Jason MillerJason Miller Nov 12, 2026 869 views

Question details

Calculate an average for records matching a selected day while excluding zero values and avoiding a division-by-zero error when no positive values match.

Use AVERAGEIFS Without Zeros or #DIV/0! Errors in WPS Spreadsheet
Product
Microsoft Excel spreadsheet formulas
Device & OS
not provided
Scenario
The user needs to average values in column F for a day such as Tuesday in column B, while ignoring zero entries.
Observed behavior
AVERAGEIFS returns a #DIV/0! error when no positive records meet the selected day and value criteria.
Before you start

Confirm that the day names in column B are consistent, such as Tuesday, and that the values in F2:F42 are stored as numbers. Adjust the row ranges and day criterion to match your worksheet.

Solution 1Recommended

Wrap AVERAGEIFS with IFERROR to return a blank

Use this option when you want to exclude zeros and display a blank cell instead of #DIV/0! when no qualifying values exist.

AVERAGEIFS can apply both the day condition and a greater-than-zero condition. IFERROR handles the error produced when the formula finds no values to average.

1
Select the result cell

Click the cell where you want the calculated average to appear.

2
Enter the formula

Type `=IFERROR(AVERAGEIFS($F$2:$F$42,$B$2:$B$42,"Tuesday",$F$2:$F$42,">0"),"")` and press Enter.

3
Change the day when needed

Replace `"Tuesday"` in the formula with another criterion, such as `"Thursday"`, to calculate that day's average.

Wrap AVERAGEIFS with IFERROR to return a blank
Result: The formula averages only values greater than zero for Tuesday and returns a blank if there are no matching positive values.
Calculate clean conditional averages

Exclude Zero Values from AVERAGEIFS in WPS Spreadsheet

WPS Spreadsheet supports AVERAGEIFS, IFERROR, and SUMIFS formulas for calculating day-specific averages without including zeros or displaying #DIV/0! when no records qualify.

  1. 1. Open the workbook in WPS Spreadsheet: Launch WPS Office, select Spreadsheets, and open the Excel workbook containing the day and value columns.
  2. 2. Choose an output cell: Click the cell where the selected day's average should be displayed.
  3. 3. Add the protected AVERAGEIFS formula: Enter `=IFERROR(AVERAGEIFS($F$2:$F$42,$B$2:$B$42,"Tuesday",$F$2:$F$42,">0"),"")` in the formula bar.
  4. 4. Confirm the calculation: Press Enter, then replace Tuesday with another day name whenever you need a different conditional average.
Use AVERAGEIFS criteria to average only values greater than zero.Handle missing qualifying records with IFERROR or IF conditions.Open and edit Microsoft Excel .xlsx and .xls workbooks with formula compatibility.Use a familiar spreadsheet interface for formulas, ranges, and cell references.
microsoft office alternative - wps office

Frequently Asked Questions

Why does AVERAGEIFS return #DIV/0! instead of an average?

AVERAGEIFS returns #DIV/0! when no cells meet all criteria. Wrap it with IFERROR, such as `=IFERROR(AVERAGEIFS(...),"")`, to return a blank instead.

How do I exclude zero values from an AVERAGEIFS calculation?

Add the average range as an additional criteria range and use the criterion `">0"`. For example, use `$F$2:$F$42,">0"` after the day criterion.

Can I use a cell reference instead of typing Tuesday in the formula?

Yes. If cell H2 contains the target day, use `=IFERROR(AVERAGEIFS($F$2:$F$42,$B$2:$B$42,H2,$F$2:$F$42,">0"),"")`.

How can I show a dash when there are no matching values?

Use a dash as the IFERROR result: `=IFERROR(AVERAGEIFS($F$2:$F$42,$B$2:$B$42,"Tuesday",$F$2:$F$42,">0"),"-")`.