🟠 Advanced 15 minadvanced path
VLOOKUP, HLOOKUP, XLOOKUP
Lookups pull data from one table into another. XLOOKUP is the modern replacement; VLOOKUP is still everywhere so you must know both.
Learning objectives
- Write a working VLOOKUP with exact match.
- Replace it with XLOOKUP and understand why it's better.
Step-by-step
1. VLOOKUP syntax
=VLOOKUP(lookup, table, col#, FALSE). Always use FALSE for exact match. The lookup column must be the leftmost column of the table.
2. HLOOKUP
Same idea horizontally. Rarely useful — most data is column-oriented.
3. XLOOKUP
=XLOOKUP(lookup, lookup_array, return_array, [if_not_found]). Lookup and return can be any column, in either direction. Cleaner and safer than VLOOKUP.
4. Handling misses
Wrap VLOOKUP in IFERROR, or use XLOOKUP's fourth argument to return a friendly message like "Not found".
Key takeaways
- Write a working VLOOKUP with exact match.
- Replace it with XLOOKUP and understand why it's better.
Related lessons
Excel Basics: The Ribbon, Cells, and Saving
12 min • Beginner
Your First Formulas: SUM, AVERAGE, and Basic Math
15 min • Easy
Lookups: VLOOKUP and XLOOKUP Explained
20 min • Intermediate
Pivot Tables in Under 20 Minutes
20 min • Advanced