How to correct a #VALUE! error in AVERAGE or SUM functions

If AVERAGE or SUM refer to cells that contain #VALUE! errors, the formulas will result in a #VALUE! error.

#VALUE! error in AVERAGE

In order to overlook the error values, we’ll construct a formula that ignores the errors in the reference range while calculating the average with the remaining “normal” values.

To work around this scenario, we use a combination of AVERAGE along with IF and ISERROR to determine if there is an error in the specified range. This particular scenario requires an array formula:


Note: This is an Array formula and needs to be entered with CTRL+SHIFT+ENTER. Excel will automatically wrap the formula in braces {}. If you try to enter them yourself Excel will display the formula as text.

Array function in AVERAGE to resolve the #VALUE! error

Note: The above function will not only work for #VALUE!, but also for #N/A, #NULL, #DIV/0!, and others.

You could also use SUM in the same fashion:


Do you have a specific function question?

Post a question in the Excel community forum

Help us improve Excel

Do you have suggestions about how we can improve the next version of Excel? If so, please check out the topics at Excel User Voice.

See Also

Correct a #VALUE! error

AVERAGE function

SUM function

Overview of formulas in Excel

How to avoid broken formulas

Use error checking to detect errors in formulas

All Excel functions (alphabetical)

All Excel functions (by category)

Expand your Office skills
Explore training
Get new features first
Join Office Insiders

Was this information helpful?

Thank you for your feedback!

Thank you for your feedback! It sounds like it might be helpful to connect you to one of our Office support agents.