XLOOKUP vs VLOOKUP in Google Sheets comes down to one difference: VLOOKUP finds a value by column number, XLOOKUP by the actual column you point at. That is why VLOOKUP breaks when someone inserts a column and XLOOKUP does not. Below you get a side-by-side example on sample data, the syntax of both, a step-by-step way to convert old formulas and fixes for #N/A.
Quick answer: Use XLOOKUP for anything you will keep or share. It looks left or right, returns several columns at once, has a built-in “not found” value and keeps working when columns are inserted. VLOOKUP only looks right and depends on a column number.
- Find a VLOOKUP such as =VLOOKUP(A2, Products!A:E, 4, FALSE).
- Take its first column as the lookup range: Products!A:A.
- Turn the column number into a range: column 4 of A:E is Products!D:D.
- Write =XLOOKUP(A2, Products!A:A, Products!D:D, "Missing product").
- Test a few known keys, including one that does not exist.
In this guide
- XLOOKUP vs VLOOKUP on sample data
- What XLOOKUP can do that VLOOKUP can’t
- Where VLOOKUP still works (and when to keep it)
- XLOOKUP syntax in Google Sheets
- VLOOKUP refresher (why it breaks)
- Convert your VLOOKUPs to XLOOKUPs (step‑by‑step)
- Advanced patterns you’ll actually use
- Error handling, arrays, and performance tips
- INDEX MATCH vs XLOOKUP (do you still need it?)
- Implementation guide: migrate a sheet in 30 minutes
- Templates and resources
- Related guides
- Trusted sources and official docs
- Common XLOOKUP and VLOOKUP errors
- Frequently Asked Questions
- Next steps
XLOOKUP vs VLOOKUP on sample data
Here is a small Products tab:
| A | B | C | D | |
|---|---|---|---|---|
| 1 | SKU | Name | Category | Price |
| 2 | SKU-100 | Desk lamp | Lighting | 24 |
| 3 | SKU-200 | Office chair | Furniture | 149 |
| 4 | SKU-300 | Monitor arm | Accessories | 59 |
On an Orders tab, cell A2 holds SKU-200. These formulas give the following results:
| Formula | Result |
|---|---|
=VLOOKUP(A2, Products!A:D, 4, FALSE) | 149 |
=XLOOKUP(A2, Products!A:A, Products!D:D, "Missing product") | 149 |
=XLOOKUP(A2, Products!A:A, Products!B:D, "Missing product") | Office chair | Furniture | 149 (three cells) |
=XLOOKUP("Office chair", Products!B:B, Products!A:A) | SKU-200 (a left lookup VLOOKUP cannot do) |
=XLOOKUP("SKU-999", Products!A:A, Products!D:D, "Missing product") | Missing product |
Now insert a new column at C in Products, for example Color. Price moves to column E. The VLOOKUP range grows to A:E but still asks for column 4, so it now returns Furniture, with no error to warn you. The XLOOKUP reference changes to Products!E:E by itself and still returns 149.
What XLOOKUP can do that VLOOKUP can’t
- Look left or right: No more rearranging tables just to match on a left column.
- Return multiple columns at once: Spill a whole row of results in one go.
- Safe when the layout changes: inserting or moving columns doesn’t break the formula.
- Built‑in not‑found handling: Friendly messages instead of raw #N/A.
- Match modes: Exact match, next smaller, or next larger—powerful for pricing tiers and ranges.
Where VLOOKUP still works (and when to keep it)
- One‑off quick checks in small ad‑hoc tables.
- Legacy sheets where changing formulas is risky today.
- Team members who only know VLOOKUP and need a short‑term fix.
XLOOKUP syntax in Google Sheets
The syntax:
=XLOOKUP(search_key, lookup_range, result_range, [missing_value], [match_mode], [search_mode])- search_key: the value you’re matching (e.g., an email or SKU)
- lookup_range: the column or row that contains the key
- result_range: the column(s) or row(s) to return
- missing_value (optional): message or value when no match is found
- match_mode (optional): 0 exact (default), -1 exact or next smaller, 1 exact or next larger, 2 wildcard
- search_mode (optional): 1 first to last (default), -1 last to first, 2 or -2 binary search on data sorted ascending or descending
- Exact match (typical lookup):
=XLOOKUP(A2, Customers!A:A, Customers!D:D, "Not found") - Multiple columns at once (spill):
=XLOOKUP(A2, Products!A:A, Products!C:E, "Missing product") - Wildcard (match SKU prefix):
=XLOOKUP(A2 & "*", Catalog!A:A, Catalog!B:B, "No SKU", 2) - Tiered pricing (next smaller):
=XLOOKUP(B2, Tiers!A:A, Tiers!B:B, "No tier", -1)
VLOOKUP refresher (why it breaks)
Syntax:=VLOOKUP(search_key, range, index, [is_sorted])
- Can only return from a column to the right of the search column.
- Relies on a numeric index; insert a column and your index becomes wrong.
- is_sorted defaults to TRUE, which needs sorted data and returns approximate matches. Forget to pass FALSE and you get wrong results without an error.
=IFERROR(VLOOKUP(A2, Products!A:E, 4, FALSE), "Missing product")=XLOOKUP(A2, Products!A:A, Products!D:D, "Missing product")
Convert your VLOOKUPs to XLOOKUPs (step‑by‑step)
- Identify the search_key column used in VLOOKUP (first column of the range).
- Replace the VLOOKUP range with two ranges: lookup_range and result_range.
- Remove the VLOOKUP index; XLOOKUP uses explicit return ranges.
- Set
[missing_value]to keep user‑friendly messages. - Optional: choose a
[match_mode]if you need tiered or wildcard matching.
=IFERROR(VLOOKUP(A2, SKUs!A:H, 6, FALSE), "No match") After (XLOOKUP): =XLOOKUP(A2, SKUs!A:A, SKUs!F:F, "No match")
Advanced patterns you’ll actually use
Multi‑criteria lookup (email + date)
Build a helper key inline using& and use wildcard if needed.
=ARRAYFORMULA(XLOOKUP(
A2 & "|" & TEXT(B2, "yyyy-mm-dd"),
Table!A2:A & "|" & TEXT(Table!B2:B, "yyyy-mm-dd"),
Table!E2:E,
"No record"
))2D lookup (row & column headers)
Combine two XLOOKUPs: one to find the column, one to find the row.=XLOOKUP(A2, Items!A2:A999,
XLOOKUP(B1, Items!B1:Z1, Items!B2:Z999),
"Missing")Partial text matches (contains)
=XLOOKUP("*" & A2 & "*", Descriptions!B:B, Descriptions!C:C, "No match", 2)Return a whole record (spill)
=XLOOKUP(A2, Leads!A:A, Leads!B:G, "Not found")
Error handling, arrays, and performance tips
- Friendly errors: Use
[missing_value]to avoid nested IFERROR in most cases. - ARRAYFORMULA: To fill a whole column from one cell, wrap the lookup:
=ARRAYFORMULA(XLOOKUP(A2:A, Products!A:A, Products!D:D, "")). This works for a single result column; a multi-columnresult_rangeonly spills for one search key at a time. - Range size: If a sheet gets slow, bound large lookups (
A2:A5000instead ofA:A). - Data types: Ensure numbers are numbers; stray text digits cause misses. Use VALUE to coerce if needed.
INDEX MATCH vs XLOOKUP (do you still need it?)
INDEX MATCH used to be the flexible alternative to VLOOKUP. XLOOKUP now consolidates that power with clearer syntax and extras like[missing_value] and match modes. Keep INDEX MATCH in your toolkit for niche array gymnastics, but for day‑to‑day business lookups, XLOOKUP wins. INDEX MATCH example for context: =INDEX(Products!D:D, MATCH(A2, Products!A:A, 0)) Equivalent XLOOKUP: =XLOOKUP(A2, Products!A:A, Products!D:D, "Missing product")
Implementation guide: migrate a sheet in 30 minutes
- Audit: Find your top 5 VLOOKUP formulas (use Find for “VLOOKUP(”).
- Map: For each, write down search key, lookup column, return column(s), and desired not‑found text.
- Replace: Convert one formula at a time to XLOOKUP. Test with 3–5 known cases.
- Spill where helpful: Replace chains of VLOOKUPs with one XLOOKUP that returns multiple columns.
- Document: Add a note near the header: “Uses XLOOKUP, exact match.”
- Lock: Protect key ranges to prevent accidental column inserts that could confuse teammates.
Templates and resources
- Google’s official XLOOKUP help: support.google.com/docs/answer/12405947
- Google’s VLOOKUP help: support.google.com/docs/answer/3093318
- Function list (Sheets): support.google.com/docs/table/25273
Related guides
- REGEXEXTRACT in Google Sheets: clean messy keys (IDs, emails) before you look them up.
- IMPORTRANGE master sheet guide: look up values across files.
Trusted sources and official docs
- Google Sheets: XLOOKUP: support.google.com/docs/answer/12405947
- Google Sheets: VLOOKUP: support.google.com/docs/answer/3093318
- Google Sheets function reference: support.google.com/docs/table/25273
- Google: FILTER function: support.google.com/docs/answer/3093197
- Google: MATCH function: support.google.com/docs/answer/3093378
- Google: INDEX function: support.google.com/docs/answer/3098242
Common XLOOKUP and VLOOKUP errors
- #N/A with no missing_value set: no match was found. Add the fourth argument (
"Not found") to show a message, then check why the key is missing. - #N/A although the value is clearly there: usually a type or spacing mismatch, such as the number
200against the text"200", or a trailing space. Clean the key column withTRIMorVALUE, or look upTRIM(A2). - #VALUE! about range sizes:
lookup_rangeandresult_rangecover different rows, for exampleA2:A100andD1:D100. Make both start and end on the same rows. - #REF! “Array result was not expanded because it would overwrite data”: a multi-column XLOOKUP needs empty cells to its right. Clear them or return fewer columns.
- VLOOKUP returns a wrong value without an error: the last argument is missing or TRUE, so it does an approximate match on unsorted data; or a column was inserted and the index now points at a different column. Pass
FALSE, or switch to XLOOKUP.
Frequently Asked Questions
Is XLOOKUP available in Google Sheets?
Yes. Google Sheets has had XLOOKUP since 2022, with the same core behavior as Excel’s version: separate lookup and result ranges, an optional not-found value, match modes and search modes. Files that use it keep working when you download them for current versions of Excel.
Why does my XLOOKUP return #N/A?
Because no row matched the search key exactly. The usual causes are numbers stored as text, extra spaces or a slightly different spelling. Clean the data with TRIM or VALUE, and set the fourth argument so real misses show a clear message instead of #N/A.
Can XLOOKUP look to the left?
Yes. Unlike VLOOKUP, XLOOKUP can return from any column or row, because the result range is separate from the lookup range. Point result_range at a column to the left of the key, as in the "Office chair" example above.
Should I still learn INDEX MATCH?
It is worth understanding, because many older sheets use it and it works in every spreadsheet app. For new formulas in Google Sheets, XLOOKUP covers almost all INDEX MATCH cases with shorter syntax and a built-in not-found value.
Which is faster, XLOOKUP or VLOOKUP?
For normal business sheets the speed difference is too small to notice. XLOOKUP can make a sheet lighter overall, because one formula can return several columns where you needed several VLOOKUPs. Bounding ranges such as A2:A5000 matters more for speed than the choice of function.
Next steps
Search your sheet for VLOOKUP(, convert the five formulas that break most often, and test each with a known key and a missing one. If you repeat the same lookup in many places, wrap it in a reusable formula with Google Sheets named functions. For filtering and summarizing rather than single lookups, use the QUERY function.

