Lookup & Reference
Lookup & Reference
Lookup & Reference
Math & Trigonometry
Statistical
XLOOKUP Formula
The modern successor to VLOOKUP. Finds a value in a range or array and returns the corresponding value from another range or array. Safer, simpler, and searches in any direction.
=XLOOKUP(lookup_value, lookup_array, return_array, [if_not_found], [match_mode], [search_mode])Parameters
The value you want to search for (e.g. a product ID or name).
The column or row range containing the search keys (e.g. A2:A50).
The column or row range containing the values to return (e.g. C2:C50).
Text or value to return if no match is found (e.g. "Not Found"). Defaults to error if empty.
Specify match type: 0 for exact match (default), -1 for exact/next smallest, 1 for exact/next largest, 2 for wildcard.
Example Usage
=XLOOKUP("Widget A", A2:A10, B2:B10, "Out of Stock")Searches for "Widget A" in column A (A2:A10) and returns the matching price from column B (B2:B10). If "Widget A" isn't found, it returns "Out of Stock".
XLOOKUP is only available in newer versions of Excel (Excel 365, Excel 2021+). If you share spreadsheets with users running older Excel versions, they will see a #NAME? error.