IFERROR vs IFNA

IFERROR catches any error; IFNA only the "not found" #N/A.

IFERRORIFNA
Catches #N/AYesYes
Catches #DIV/0!, #NAME?, #REF!YesNo
RiskHides real formula mistakesNone: other errors stay visible

Syntax and example

IFERROR

=IFERROR(value, value_if_error)

=IFERROR(B2/C2,0)

Returns a formula’s result or, if it returns any error, the value you choose.

IFNA

=IFNA(value, value_if_na)

=IFNA(VLOOKUP(D2,$A$2:$B$6,2,FALSE),"No price")

Returns an alternative value only when the formula returns #N/A (not found).

Which one to use?

With lookups, IFNA: a misspelled function name will not be hidden. IFERROR for divisions and calculations that can fail in several ways.

About Ads

This site uses Google AdSense to display ads. These ads help us keep WebHerramientas completely free. Ads are managed by Google and meet strict security and privacy standards.

Advertising
Loading ad...

Ads help us keep WebHerramientas free for everyone

Practice it

Solve the exercise on the sheet; it is checked instantly. See all lessons · Formula translator

IFNA

IFNA is like IFERROR, but it only catches #N/A, the "not found" error. That way you do not hide other errors you do want to see.

Example=IFNA(VLOOKUP(D2,$A$2:$B$6,2,FALSE),"Sin precio")SI.ND = IFNABUSCARV = VLOOKUPBUSCARX = XLOOKUPINDICE = INDEX

In E2, look up the price for the code in D2. If it does not exist, show "No price".

E2
ABCDEF
1CodePriceFindPrice
2P-1011,299P-103
3P-102189P-110
4P-10395P-105
5P-104459P-999
6P-105239
7

Tip: while typing, click a cell or drag across several to insert their reference. F4 anchors the reference with $.

Frequently asked questions

What is the difference between IFERROR and IFNA?
IFERROR catches any error; IFNA only the "not found" #N/A.
When should I use IFERROR or IFNA?
With lookups, IFNA: a misspelled function name will not be hidden. IFERROR for divisions and calculations that can fail in several ways.