#N/A error: what it means and how to fix it
A lookup (VLOOKUP, XLOOKUP, MATCH, INDEX with MATCH) could not find the value you asked for. The formula is fine; the value is not where you said it would be.
The usual causes
- The value really is not in the list, often because of a typo.
- An extra space, usually at the end of a name copied from somewhere else, so "Pear " does not match "Pear".
- A number stored as text on one side and as a number on the other.
- The last VLOOKUP argument is missing or TRUE on an unsorted list, so it searches approximately.
How to fix it
- Check the spelling of the value you are looking up.
- Wrap it in TRIM to remove stray spaces: =VLOOKUP(TRIM(D2),A2:B4,2,FALSE).
- Use FALSE (or 0) as the last VLOOKUP argument for an exact match.
- Only when "not found" is a normal answer, show a message with IFERROR or the fourth XLOOKUP argument. Do not hide errors you have not understood.
Fix a broken formula live
D2 contains "Banana " with a space at the end. Cell E2 shows #N/A. Change the formula in the bar until the error goes away, or press “Show the fix”.
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | ||||||
| 2 | ||||||
| 3 | ||||||
| 4 | ||||||
| 5 | ||||||
| 6 | ||||||
| 7 | ||||||
| 8 |
#N/A A lookup (VLOOKUP, XLOOKUP, MATCH, INDEX with MATCH) could not find the value you asked for. The formula is fine; the value is not where you said it would be.
Uses VLOOKUP. Start with the free spreadsheet lessons →
Runs in your browser; nothing you type is sent anywhere. Works like Excel, Google Sheets and LibreOffice Calc for the common functions.
Learn the skill behind it
Practice cell references in the free formula lesson →
Find a row with VLOOKUP in the Pro lesson →