How to use the XLOOKUP function in Excel

XLOOKUP finds a value in one column and returns the matching value from another column in the same row. It suits beginners who know basic Excel formulas and need to search tables quickly. You need a version of Excel that includes XLOOKUP, such as Microsoft 365.

YouTube video: How to Use XLOOKUP in Excel | Easy XLOOKUP Formula Tutorial for Beginners

YouTube’s video details do not confirm captions. Check CC in the player for available tracks.

Video length
1 min 7 s
Time to do it
5 minutes
Difficulty
Easy
Steps
7

What you need

Steps

  1. Click the cell where you want the result to appear.

  2. Type =XLOOKUP( to start the formula.

  3. Enter the lookup value, such as a name or ID, or click the cell that holds it.

  4. Select the lookup array, the column where Excel should search for that value.

  5. Select the return array, the column that holds the value you want back.

  6. Close the bracket and press Enter to run the formula.

  7. Drag the fill handle down to copy the formula to other rows.

Tips and common mistakes

The lookup array and return array must have the same number of rows, or Excel returns an error.

Add a fourth argument, such as "Not found", to show a message when no match exists.

XLOOKUP searches from the first row by default, so you do not need to sort your table.

Questions

What is the difference between XLOOKUP and VLOOKUP?

XLOOKUP can search in any direction and return values from columns to the left, while VLOOKUP only looks to the right. XLOOKUP also has a built-in option for when no match is found.

Why do I get a #NAME? error?

Your Excel version likely does not include XLOOKUP. It is available in Microsoft 365 and Excel 2021 and later, so update Excel or use INDEX and MATCH instead.

Can XLOOKUP search from the bottom up?

Yes. Add -1 as the sixth argument to search from the last row upward, which is useful for finding the most recent entry.

The notes are drafted automatically from video details and general task knowledge. How the guide was prepared

Report a correction

More in Apps & Software

See all