Xlookup formula returns #N/A

Kay 20 Reputation points
2026-08-04T08:36:13.6933333+00:00

How to fix Xlookup formula if it returns no value, although source data contains that value?

Microsoft 365 and Office | Excel | Other | Other
0 comments No comments

Answer accepted by question author
Marcin Policht 104.1K Reputation points MVP Volunteer Moderator
2026-08-04T11:10:59.5566667+00:00

First verify that the lookup values are truly identical. Hidden spaces, nonprinting characters, different data types (text versus numbers), or slight formatting differences can prevent a match. Use functions such as TRIM(), CLEAN(), VALUE(), or TEXT() to normalize the data if necessary.

Confirm that the lookup array and return array are the correct ranges and have the same dimensions. Also check that the lookup value is not an error or an empty string, and that the source workbook or worksheet is available if the data is external.

If you are using the default exact-match behavior, ensure the value exists exactly as entered. If you need wildcard matching, set the match_mode argument to 2 and use * or ? in the lookup value. If the formula uses an approximate match (match_mode 1 or -1), make sure the lookup array is sorted.

To troubleshoot, test the lookup value with =EXACT(), =ISTEXT(), =ISNUMBER(), or =LEN() to identify hidden differences. You can also use =MATCH() or Evaluate Formula (Formulas > Evaluate Formula) to determine why the lookup is failing.


If the above response helps answer your question, remember to "Accept Answer" so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.

hth

Marcin

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.