FormulaCraft

How to average ignoring zeros in Excel and Google Sheets

Topic:AVERAGE & central tendency
Excel & Google Sheets
=AVERAGEIF(B2:B6,"<>0")

Verified example

Computed by a real spreadsheet engine on the sample data below.

MonthSales
Jan0
Feb150
Mar0
Apr200
May175

=AVERAGEIF(B2:B6,"<>0")175

Try it with your data

Edit the grid or formula, then run it through a real spreadsheet engine — no signup.

Sample data — click any cell to edit

Runs server-side · free · no signup

Step by step

  1. 1Select the output cell.
  2. 2Type =AVERAGEIF(.
  3. 3Select the range of values, e.g. B2:B6.
  4. 4Enter the criterion "<>0" to exclude zeros.
  5. 5Close the parenthesis and press Enter.

Tips

Working on a sheet you inherited? Run the Auditor on the whole file first — it flags every #REF!, #N/A, broken column pattern, and inconsistent formula in seconds, free, no signup.

Frequently asked

What if I want to exclude zeros and blanks?

AVERAGEIF already ignores blanks. Just use =AVERAGEIF(B2:B6,"<>0") and both zeros and blanks are excluded.

Can I use AVERAGEIFS to exclude zeros and apply another condition?

Yes. =AVERAGEIFS(B2:B6,B2:B6,"<>0",A2:A6,"North") averages non-zero values in the North region.

More on AVERAGE & central tendency

See all →

Formulas used

Related tasks

Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.

Last reviewed: