IFNA Function
Replaces #N/A errors with a fallback value.
Syntax
Parameters
| Parameter | Description | Required |
|---|---|---|
| value | The expression, formula, or cell to evaluate. | Required |
| value_if_na | The value returned if value evaluates to #N/A. | Required |
Basic Example
Catch a missing lookup
=IFNA(VLOOKUP("Z",A1:B5,2,FALSE),"Not found")When the lookup finds no match it returns #N/A, which IFNA replaces with "Not found".
Advanced Examples
Example 1: Return zero instead of #N/A
A lookup may missUse a numeric fallback for math
=IFNA(VLOOKUP(A1,Table,2,FALSE),0)Example 2: IFNA vs IFERROR
A formula might return #DIV/0!IFNA leaves other errors untouched
=IFNA(1/0,"NA only")How IFNA Works
IFNA evaluates value first; if the result is the #N/A error it returns value_if_na, otherwise it returns the original result. It deliberately ignores all other error types.
Important Notes & Limitations
Only catches #N/A; use IFERROR to catch all error types.
Available in Excel 2013 and later.
If value_if_na is itself an error, that error is returned.
Common Errors & Fixes
Other errors not caughtIFNA only handles #N/A, so #VALUE!, #DIV/0!, etc. pass through.Fix: Use IFERROR if you need to catch every error type.
Download Practice File
IFNA
ifnaPractice IFNA with Real Data
Download a sample CSV file with pre-populated data and practice exercises for the IFNA function. Works in both Excel and Google Sheets.
File format: CSV (comma-separated values) - opens in Excel, Google Sheets, and all spreadsheet apps