VLOOKUP vs XLOOKUP
XLOOKUP is the modern VLOOKUP: it looks in any direction, matches exactly by default and handles "not found" without IFERROR.
| VLOOKUP | XLOOKUP | |
|---|---|---|
| Available in | Every version | Excel 365 and 2021 |
| Default match | Approximate (you must add FALSE) | Exact |
| Lookup column | Only the first one in the range | Any, even to the right |
| If not found | #N/A (needs IFERROR) | Fourth argument |
| If you insert columns | The column number goes stale | Keeps working |
Syntax and example
VLOOKUP
=VLOOKUP(lookup_value, table_array, col_index_num, [range_lookup])
=VLOOKUP(F2,A2:C8,3,FALSE)
Looks up a value in a table’s first column and returns data from another column on that row.
XLOOKUP
=XLOOKUP(lookup_value, lookup_array, return_array, [if_not_found])
=XLOOKUP(E2,$A$2:$A$7,$C$2:$C$7,"Not found")
The modern lookup in Excel 365 and 2021: it searches in any direction and matches exactly by default.
Which one to use?
Use XLOOKUP if everyone opening the file has Excel 365 or 2021. Use VLOOKUP if it will be shared with older versions, and do not forget FALSE.
About Ads
This site uses Google AdSense to display ads. These ads help us keep WebHerramientas completely free. Ads are managed by Google and meet strict security and privacy standards.
Ads help us keep WebHerramientas free for everyone
Practice it
Solve the exercise on the sheet; it is checked instantly. See all lessons · Formula translator
XLOOKUP
XLOOKUP(value, lookup_range, return_range, if_not_found) is Excel 365’s modern lookup: it searches in any direction, matches exactly by default and lets you choose what to show when nothing is found.
In F2, look up the average for the ID in E2. It will be copied to F3, whose ID does not exist; in that case show "Not found".
| A | B | C | D | E | F | G | |
|---|---|---|---|---|---|---|---|
| 1 | Student ID | Student | Average | Find | Average | ||
| 2 | A-2201 | Ana | 9.2 | A-2204 | |||
| 3 | A-2202 | Luis | 7.8 | A-2299 | |||
| 4 | A-2203 | Sofía | 8.6 | ||||
| 5 | A-2204 | Diego | 6.9 | ||||
| 6 | A-2205 | Valeria | 9.7 | ||||
| 7 | A-2206 | Mateo | 8.1 | ||||
| 8 |
Tip: while typing, click a cell or drag across several to insert their reference. F4 anchors the reference with $.
Frequently asked questions
- What is the difference between VLOOKUP and XLOOKUP?
- XLOOKUP is the modern VLOOKUP: it looks in any direction, matches exactly by default and handles "not found" without IFERROR.
- When should I use VLOOKUP or XLOOKUP?
- Use XLOOKUP if everyone opening the file has Excel 365 or 2021. Use VLOOKUP if it will be shared with older versions, and do not forget FALSE.