🔎 Google Sheets lookup examples

Xlookup Examples in Google Sheets

Search a lookup range and return a matching value from another range. This page gives a clear pattern, five practical examples and common mistakes to avoid.

Updated 2026-06-125 practical examplesCopy-ready formulas

💡 Ideas for You

Learning resources for Google Sheets formulas, trackers and reports.

4 useful links

Some links in this section may be affiliate links. Choose only what is useful for your own work.

Syntax or pattern

Search a lookup range and return a matching value from another range.

=XLOOKUP(search_key, lookup_range, result_range, [missing_value])
✍️

5 practical examples

1

Use XLOOKUP to find a product price

Return the matching product price from a lookup table.

=XLOOKUP(A2, Products!A:A, Products!B:B, "Not found")

Adjust the ranges, criteria and sheet names to match your workbook.

2

Use XLOOKUP for employee details

Find a department, manager, or role from an employee ID.

=XLOOKUP(E2, Staff!A:A, Staff!C:C, "Check ID")

Adjust the ranges, criteria and sheet names to match your workbook.

3

Use XLOOKUP with a status table

Convert status codes into readable labels.

=XLOOKUP(B2, StatusMap!A:A, StatusMap!B:B, "Unknown")

Adjust the ranges, criteria and sheet names to match your workbook.

4

Use XLOOKUP to pull a category

Return a category for reporting and summaries.

=XLOOKUP(A2, Items!A:A, Items!D:D, "No category")

Adjust the ranges, criteria and sheet names to match your workbook.

5

Use XLOOKUP with imported data

Look up a value from an imported or shared tab.

=XLOOKUP(A2, Imported!A:A, Imported!B:B, "Missing")

Adjust the ranges, criteria and sheet names to match your workbook.

Common mistakes to avoid

  • Using lookup ranges and return ranges with different row counts.
  • Leaving extra spaces in lookup values.
  • Forgetting a fallback value when a lookup can be missing.

FAQ

What is this Google Sheets page for?

This page gives copy-ready examples for xlookup examples so you can understand the pattern and adapt it to real spreadsheet work.

Can I copy these formulas directly?

Yes. Use the copy buttons, then adjust sheet names, ranges, criteria and column references for your own file.

Why does my formula return an error?

The most common causes are mismatched ranges, missing quotes around text criteria, blank source data, or references that do not match your sheet layout.