ISNA – Test if cell is #N/A – Excel, VBA, & Google Sheets

Written by

Editorial Team

Reviewed by

Steve Rynearson

Last updated on November 6, 2023
Download Example Workbook

Download the example workbook

This tutorial demonstrates how to use the ISNA Function in Excel and Google Sheets to test if a cell results in #N/A.

ISNA Main

How to use the ISNA Function

The ISNA Function checks if a calculation results in any error, except the #N/A error.

=ISNA(A2)

ISNA

ISERROR, ISERR, and ISNA

There are two other error checking “is” functions:

ISNA ISERR

The different “is error” functions exist so you can decide what to do about potentially valid #N/A errors.

IFNA Function

Instead of the ISNA Function, you can also use the IFNA Function to do something if an error is detected (instead of simply returning TRUE / FALSE).

IFNA

Other Logical Functions

Excel / Google Sheets contain many other logical functions to perform other logical tests. Here is a list:

IF / IS Functions
iferror
iserror
isna
iserr
isblank
isnumber
istext
isnontext
isformula
islogical
isref
iseven
isodd

ISNA in Google Sheets

The ISNA Function works exactly the same in Google Sheets as in Excel:

ISNA Google

 

ISNA Examples in VBA

You can also use the ISNA function in VBA. Type:

application.worksheetfunction.isna(value)

On the sheet below

Vba ISNA function

 

Executing the following VBA code

Range("A2") = Application.WorksheetFunction.IsNA(Range("A1"))
Range("B2") = Application.WorksheetFunction.IsNA(Range("B1"))

will return TRUE for cell A1, which is #N/A, and false for cell B2 which is 5

For the function arguments (value, etc.), you can either enter them directly into the function, or define variables to use instead.

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 List of Excel Functions