If ISNA & IFNA in VLOOKUPs – Excel & Google Sheets

Written by

Editorial Team

Reviewed by

Steve Rynearson

Last updated on April 10, 2023
Download Example Workbook

Download the example workbook

This tutorial will demonstrate how to handle VLOOKUP #N/A errors in Excel and Google Sheets. If you have access to the XLOOKUP Function, read our article on handling XLOOKUP errors.

if isna vlookup Main Function

IFNA in VLOOKUP

When you lookup a value with the VLOOKUP Function, if the value is not found, VLOOKUP will return the #N/A error.

=VLOOKUP(E3,B3:C6,2,FALSE)

if-isna-vlookup-0

You can add the IFNA Function outside of the VLOOKUP, to do something else if the VLOOKUP results in an IFNA error. In this example, we will output “Not found” if the VLOOKUP results in an #N/A error:

=IFNA(VLOOKUP(E3,B3:C6,2,FALSE),"Not found")

if isna vlookup 1

Note: The new XLOOKUP Function has built-in error handling. The IFNA Function is not needed!

Another common use of the IFNA Function is to perform a second VLOOKUP if the first VLOOKUP can not find the value. This may be used if a value could be found on one of two sheets; if the value is not found on the first sheet, lookup the value on the second sheet instead.

=IFNA(VLOOKUP(E3,B3:C6,2,FALSE),VLOOKUP(E3,'Data'!B3:C6,2,FALSE))

if isna vlookup in ifna function

IF ISNA in VLOOKUP

The IFNA Function was introduced in Excel 2013. Prior to that, you had to use the more complicated IF / ISNA combination:

=IF(ISNA(VLOOKUP(E3,B3:C6,2,FALSE)),"Not found",VLOOKUP(E3,B3:C6,2,FALSE))

if isna vlookup 2

The ISNA function checks whether the result of the VLOOKUP formula is an #N/A error and returns True or False accordingly. If it is true (i.e., your lookup value is missing from the lookup array), the IF function will return with a message you specify, otherwise it will give you the result of the VLOOKUP.

IFERROR – VLOOKUP

As stated above, the IFNA Function tests if the formula outputs only a #N/A error. Instead, the IFERROR Function can be used to check if ANY error is returned:

=IFERROR(VLOOKUP(E3,B3:C6,2,FALSE),"Not found")

if isna vlookup 3

Usually it’s better to use IFNA instead of IFERROR, as IFERROR will handle errors that might need your attention.

If ISNA & IFNA in VLOOKUPs – Google Sheets

These formulas work the same in Google Sheets as in Excel.

if isna vlookup Google Function

AI Formula Generator

Try for Free

Excel Practice Worksheet

practice excel worksheet

Practice Excel functions and formulas with our 100% free practice worksheets!

  • Automatically Graded Exercises
  • Learn Excel, Inside Excel!

Free Download

Return to Excel Formulas List