Information function

ISERROR function

Returns TRUE if a value is any kind of error (#N/A, #DIV/0!, #VALUE!, #REF! and so on), otherwise FALSE.

Available in All versions of Excel, including Microsoft 365 and Excel for the web

In every Excel versionWorks in Google Sheets

Syntax

ISERROR(value)
ArgumentWhat it means
valueRequiredThe value, cell reference or formula to check.

Returns: TRUE if value is an error of any type; FALSE otherwise.

How ISERROR works

ISERROR answers a simple yes/no question: does this cell or formula result in an error? It recognises every error type — #N/A, #DIV/0!, #VALUE!, #REF!, #NAME?, #NUM!, #NULL! and the newer ones such as #SPILL! and #CALC!. Use it to flag problem rows, to count errors in a report before sending it, or inside conditional formatting to highlight them.

Before Excel 2007 the standard way to hide errors was =IF(ISERROR(formula), alternative, formula). That still works, but IFERROR does the same job in one step and calculates the formula only once, so today ISERROR is mostly used when you need the TRUE/FALSE itself rather than a replacement value.

If you only expect "not found" errors from lookups, prefer ISNA; it lets other errors — which usually point to genuine mistakes — stay visible.

Examples

1Will this division fail?

D3fx=ISERROR(B3/C3)
ABCD
1ProductRevenueUnits
2Desk420014
3Chair00TRUE

Result: TRUE

Dividing by 0 units produces #DIV/0!, so ISERROR returns TRUE. For the desk row it returns FALSE.

2Is this product code new?

C2fx=IF(ISERROR(MATCH("P-205", A2:A5, 0)), "New product", "Existing")
ABC
1Code
2P-201New product
3P-202
4P-203
5P-204

Result: New product

MATCH cannot find P-205 and returns #N/A; ISERROR detects that, and IF shows New product.

3Count errors before sending a report

D2fx=SUMPRODUCT(--ISERROR(B2:B6))
ABCD
1StoreMargin
2Athens0.182
3Berlin#N/A
4Cairo0.22
5Dublin#DIV/0!
6Essen0.09

Result: 2

ISERROR is TRUE for Berlin (#N/A) and Dublin (#DIV/0!). The double minus turns TRUE into 1 and SUMPRODUCT adds them: 2 problems to fix.

⬇Practice workbookExamples with live formulas + practice sheets · .xlsx · 16 KB

Tips

  • For replacing errors with a value, IFERROR is shorter and faster than IF(ISERROR(...)).
  • Conditional formatting rule =ISERROR(B2) with a red fill makes every error in a table stand out.
  • Many functions such as SUM fail if their range contains an error; AGGREGATE with option 6 can total a range while skipping errors.

Questions

What is the difference between ISERROR, ISERR and ISNA?

ISERROR is TRUE for every error. ISERR is TRUE for every error except #N/A. ISNA is TRUE only for #N/A.

Should I use ISERROR or IFERROR?

Use IFERROR when you want to replace an error with something else. Use ISERROR when you need a TRUE/FALSE, for example to count errors or in a conditional-formatting rule.

Google Sheets

ISERROR also exists in Google Sheets and works the same way for everyday use, so the examples above work there too.

ISERROR in other languages

In a non-English version of Excel the function has a local name. Excel translates formulas automatically when a file is opened in another language.

LanguageFunction name
CzechJE.CHYBHODN
DanishER.FEJL
DutchISFOUT
FinnishONVIRHE
FrenchESTERREUR
GermanISTFEHLER
HungarianHIBÁS
ItalianVAL.ERRORE
Norwegian (Bokmål)ERFEIL
PolishCZY.BŁĄD
Portuguese (Brazil)ÉERROS
Portuguese (Portugal)É.ERRO
RussianЕОШИБКА
SpanishESERROR
SwedishÄRFEL
TurkishEHATALIYSA