The XLOOKUP vs VLOOKUP debate comes up in almost every Excel team. VLOOKUP has been the standard lookup function for decades, while XLOOKUP is the modern replacement available in Microsoft 365, Excel 2021 and later, and Excel for the web. Both find a value in one list and return related data, but XLOOKUP fixes nearly every frustration people have with VLOOKUP.
In this guide you will see the differences side by side, with practical examples, so you can choose the right function for your workbooks.
Table of Contents
- Quick Answer
- The Syntax Side by Side
- XLOOKUP vs VLOOKUP Comparison Table
- Example 1: A Basic Lookup
- Example 2: Looking to the Left
- Example 3: Handling Missing Values
- Example 4: Returning Several Columns at Once
- Example 5: Finding the Last Match
- Example 6: Approximate Matches for Tiers
- Performance and Reliability
- Real-World Scenarios: XLOOKUP vs VLOOKUP at Work
- When You Should Still Use VLOOKUP
- How to Switch From VLOOKUP to XLOOKUP
- Frequently Asked Questions
- Conclusion
Quick Answer
If everyone who opens your file has Microsoft 365 or Excel 2021 or newer, use XLOOKUP. It is easier to write, safer when columns move, and more powerful. Use VLOOKUP when you must share files with people on Excel 2019 or older, or when you are maintaining existing workbooks that already rely on it.
The Syntax Side by Side
=VLOOKUP(lookup_value, table_array, col_index_num, [range_lookup])
=XLOOKUP(lookup_value, lookup_array, return_array, [if_not_found], [match_mode], [search_mode])
The key difference: VLOOKUP asks for a whole table and a column number. XLOOKUP asks for the column to search and the column to return as two separate ranges.
XLOOKUP vs VLOOKUP Comparison Table
| Feature | VLOOKUP | XLOOKUP |
|---|---|---|
| Default match type | Approximate (unless you add FALSE) | Exact |
| Look to the left | No | Yes |
| Breaks when columns are inserted | Yes (hard-coded column number) | No |
| Built-in “not found” message | No (needs IFERROR) | Yes |
| Search from bottom (last match) | No | Yes |
| Return multiple columns at once | No | Yes |
| Wildcard matching | Yes | Yes (match_mode 2) |
| Horizontal lookups | Needs HLOOKUP | Same function |
| Works in Excel 2019 and older | Yes | No |
| Works in Google Sheets | Yes | Yes |
Example 1: A Basic Lookup
Product codes are in A2:A100, prices in C2:C100, and the code you want is in F2.
VLOOKUP:
=VLOOKUP(F2, A2:C100, 3, FALSE)
XLOOKUP:
=XLOOKUP(F2, A2:A100, C2:C100)
XLOOKUP is shorter and exact match is the default, so you cannot accidentally forget FALSE and get wrong answers.
Example 2: Looking to the Left
Suppose employee names are in column B and IDs are in column A. You have a name and need the ID.
VLOOKUP cannot do this without rearranging columns or using INDEX MATCH. XLOOKUP simply searches B and returns A:
=XLOOKUP(H2, B2:B200, A2:A200)
Example 3: Handling Missing Values
VLOOKUP needs a wrapper:
=IFERROR(VLOOKUP(F2, A2:C100, 3, FALSE), "Not found")
XLOOKUP has it built in:
=XLOOKUP(F2, A2:A100, C2:C100, "Not found")
The XLOOKUP version is also safer, because IFERROR hides every error, including genuine mistakes in your formula, while the if_not_found argument only handles missing values.
Master modern Excel functions
Learn XLOOKUP, INDEX MATCH, FILTER, UNIQUE and VBA with real workbooks you can reuse at work.
Example 4: Returning Several Columns at Once
With XLOOKUP you can return an entire row segment. If you want name, department and salary for an ID:
=XLOOKUP(F2, A2:A200, B2:D200)
The result spills across three cells automatically. With VLOOKUP you would need three separate formulas with column numbers 2, 3 and 4.
Example 5: Finding the Last Match
If a customer appears several times in a sales log and you want their most recent purchase, set search_mode to -1 to search from the bottom up:
=XLOOKUP(F2, B2:B5000, D2:D5000, "None", 0, -1)
VLOOKUP always returns the first match from the top.
Example 6: Approximate Matches for Tiers
For commission tiers or tax brackets, VLOOKUP needs a sorted table and TRUE. XLOOKUP uses match_mode:
0exact match (default)-1exact match or next smaller item1exact match or next larger item2wildcard match
=XLOOKUP(B2, Tiers[MinSales], Tiers[Rate], , -1)
XLOOKUP does not require the tier table to be sorted when using match mode -1 or 1, which removes a common source of errors.
Performance and Reliability
On typical office datasets both functions are fast. The bigger difference is reliability:
- Inserting a column inside a VLOOKUP table silently returns the wrong column if you hard-coded
3. XLOOKUP references the return column directly, so it keeps working. - VLOOKUP’s default approximate match causes wrong results that look correct. XLOOKUP’s exact-match default prevents this.
Real-World Scenarios: XLOOKUP vs VLOOKUP at Work
Feature lists are useful, but the real test is daily work. Here is how the two functions compare in situations office users face every week.
Scenario 1: A monthly sales report that keeps changing. Your manager asks you to add a “Discount” column in the middle of the source data. Every VLOOKUP that used column number 5 now returns discount instead of revenue, and nobody notices until the totals look strange. XLOOKUP formulas point to the revenue column itself, so they keep returning revenue.
Scenario 2: An HR file sorted by name, not ID. You receive a staff list where the name is in column A and the employee ID is in column D. You need to find IDs from names. VLOOKUP handles this, because the name column is first. But when HR later asks for names from IDs, VLOOKUP fails because it cannot look left. XLOOKUP handles both directions with the same simple pattern.
Scenario 3: A price list with gaps. Some product codes in your orders do not exist yet in the price list. With VLOOKUP you see a column full of #N/A until you wrap every formula in IFERROR. With XLOOKUP you add “Check price” as the fourth argument and your report looks clean from the start.
Scenario 4: A shared file with a client. Your client uses Excel 2016. Every XLOOKUP shows #NAME? on their computer. In this case VLOOKUP, or INDEX MATCH, is the right choice no matter how good XLOOKUP is.
Scenario 5: The latest status of an order. An order log records every status change: Received, Packed, Shipped, Delivered. To show the current status, you need the last entry for each order number. VLOOKUP always returns the first entry (Received). XLOOKUP with search_mode set to -1 returns the latest one.
The pattern is clear: XLOOKUP wins on flexibility and safety, while VLOOKUP wins only on compatibility.
When You Should Still Use VLOOKUP
- Compatibility: colleagues, clients or company computers still run Excel 2016 or 2019. In those versions XLOOKUP shows
#NAME?. - Existing files: rewriting hundreds of working formulas may not be worth it.
- Job interviews: many Excel tests still ask for VLOOKUP, so you should know both.
An alternative that works everywhere and has most of XLOOKUP’s flexibility is INDEX MATCH. Learn it in how to use INDEX MATCH in Excel.
How to Switch From VLOOKUP to XLOOKUP
Converting is mechanical:
- Take the VLOOKUP lookup value: it stays the same.
- Replace the table with only its first column as the lookup array.
- Replace the column number with the actual column you want to return.
- Drop the
FALSE, because exact match is the default.
=VLOOKUP(A2, Sheet2!A:D, 4, FALSE) becomes =XLOOKUP(A2, Sheet2!A:A, Sheet2!D:D).
Build Excel skills employers test
From lookups to dashboards and macros, practice everything you need for office jobs and Excel interviews.
Frequently Asked Questions
Is XLOOKUP better than VLOOKUP?
In most cases, yes. XLOOKUP defaults to exact match, can look left, does not break when columns are inserted and has a built-in not-found message. The only major downside is that it does not work in Excel 2019 and earlier.
Which Excel versions have XLOOKUP?
XLOOKUP is available in Microsoft 365, Excel 2021, Excel 2024, Excel for the web and recent Excel mobile apps. It is not available in Excel 2019, 2016 or older.
What happens if I open an XLOOKUP file in an older Excel version?
The formulas show a #NAME? error because older versions do not recognize the function. If you share files widely, use VLOOKUP or INDEX MATCH instead.
Does Google Sheets support XLOOKUP?
Yes. Google Sheets supports XLOOKUP with a very similar syntax, so the skills transfer directly.
Should beginners learn VLOOKUP or XLOOKUP first?
Learn VLOOKUP first because it appears in countless existing files and interview tests, then move to XLOOKUP for new work. Understanding both makes you comfortable in any workplace.
Conclusion
XLOOKUP is the better tool for new work: simpler syntax, fewer mistakes and more features. VLOOKUP still matters for compatibility and legacy files. Learn both, use XLOOKUP where you can, and keep INDEX MATCH as a universal backup. For a refresher on the classic function, see our VLOOKUP in Excel tutorial.
Go from formula user to Excel expert
Learn advanced formulas, functions, VBA and macros with step-by-step video lessons.
Good to know: BUY INDIVIDUAL COURSE directly through this link gives you lifetime access, and it supports the instructor far more than watching it through a Udemy subscription plan.