XLOOKUP Formula Generator
XLOOKUP is the modern replacement for VLOOKUP and INDEX/MATCH. It can search in any direction, returns clean results, and won't break when you insert columns. Fill in the fields below to generate the exact formula, then copy it into Excel 365 or Google Sheets.
This tool runs entirely in your browser — no upload, no sign-up.
=XLOOKUP(E2, A2:A100, C2:C100, "Not found")
XLOOKUP syntax explained
The formula is =XLOOKUP(lookup_value, lookup_array, return_array, [if_not_found], [match_mode], [search_mode]).
lookup_array is the single column/row you search. return_array is the column/row whose value you want back — it can be anywhere, including to the left of the lookup array. if_not_found lets you supply a fallback (e.g. "Not found") instead of an #N/A error. match_mode 0 means exact match.
Why XLOOKUP beats VLOOKUP
It looks in any direction, so your key doesn't have to be the leftmost column.
It references ranges directly instead of a fragile column index number, so inserting or deleting columns won't silently break it.
It has a built-in if-not-found argument, removing the need to wrap everything in IFERROR.
Frequently asked questions
What is the XLOOKUP syntax?
=XLOOKUP(lookup_value, lookup_array, return_array, [if_not_found], [match_mode], [search_mode]). Use match_mode 0 for an exact match.
Is XLOOKUP available in my version of Excel?
XLOOKUP is available in Microsoft 365 and Excel 2021 and later, and in Google Sheets. If you use Excel 2019 or earlier, use VLOOKUP or INDEX/MATCH instead.
Can XLOOKUP look to the left?
Yes. Unlike VLOOKUP, XLOOKUP's return_array can be anywhere relative to the lookup_array, so it can return values to the left of your key.
Keep exploring
Analyze a whole spreadsheet with AI
Upload an Excel or CSV file and get pivots, outlier detection, and Smart BI dashboards in seconds. Free to start — no credit card.
Open the App Free