Lookup & reference

XLOOKUP function

Look up a value, return the matching item. XLOOKUP works in Sheets with the usual arguments and results, on cells and on live data from the tools you connect.

Syntax

=XLOOKUP(lookup, lookup_range, return_range, [if_not_found], [match_mode], [search_mode])
ArgumentUse
lookuprequired
lookup_rangerequired
return_rangerequired
if_not_foundoptional
match_modeoptional
search_modeoptional

Example

Look up a customer and return the amount, with a fallback when it is missing.

fx=XLOOKUP("Delta BV", B2:B7, E2:E7, "not found")
ABCDEF
1OrderCustomerRegionStatusAmountDate
2#1001Acme LtdNorthPaid12002026-01-14
3#1002Blue FoxSouthOpen4502026-01-20
4#1003Acme LtdNorthPaid9802026-02-03
5#1004Cedar & CoEastOverdue23002026-02-11
6#1005Blue FoxSouthPaid6102026-03-02
7#1006Delta BVWestOpen17502026-03-09
81,750

Result computed by the Sheets formula engine.

On live data

In Sheets, XLOOKUP sits next to live data from a connected tool: =data.orders.sum(total) totals a table, =list.orders(customer) spills a column's distinct values, and a linked table column such as table.orders[Total] is a range any function accepts.

See the integrations

More lookup & reference functions

All 37 lookup & reference functions →

Spreadsheet formulas on live business data

Sheets evaluates 491 spreadsheet functions, on cells and on data read live from your tools.