Table of Contents
XLOOKUP is a function in Google Sheets that allows users to search for a specific value in a range of cells and return a corresponding value from another column. To use XLOOKUP, the formula must include the search key, the search range, the return range, and any optional arguments. For example, “=XLOOKUP(A2,A2:A10,B2:B10)” would search for the value in cell A2 within the range A2:A10 and return the corresponding value from the range B2:B10. This function is useful for quickly finding data in a large dataset and can be used for various purposes such as data analysis and organizing information.
Use XLOOKUP in Google Sheets (With Example)
The XLOOKUP function in Google Sheets can be used to look up a value in a range and return some corresponding value.
This function uses the following basic syntax:
=XLOOKUP(search_key, lookup_range, result_range)
where:
- search_key: The value to search for.
- lookup_range: The range to search in.
- result_range: The range that contains the value to return.
The following example shows how to use this function in practice.
Example: How to Use XLOOKUP in Google Sheets
Suppose we have the following dataset in Google Sheets that contains information about various basketball players:

We can use the following XLOOKUP function in Google Sheets to look up the value in E2 in the range A2:A11 and return the corresponding value in the range C2:C11:
=XLOOKUP(E2,A2:A11, C2:C11)
The following screenshot shows how to use this formula in practice:

The XLOOKUP function looks up the value “Rockets” in column A and returns the corresponding value in the “Points” column.
Note that you can also use a fourth argument in the XLOOKUP function to specify what value should be returned if no match is found.
Note: The default is to return #N/A if no match is found.
For example, we can use the following formula to return “Not Found” if no match is found:
=XLOOKUP(E2,A2:A11, C2:C11, "Not Found")
The following screenshot shows how to use this formula in practice:

Since “Wizards” doesn’t exist in column A, a value of “Not Found” is returned.
Note: You can find the complete documentation for the XLOOKUP function .
Additional Resources
Cite this article
stats writer (2024). How can I use XLOOKUP in Google Sheets? Can you provide an example?. PSYCHOLOGICAL SCALES. Retrieved from https://scales.arabpsychology.com/stats/how-can-i-use-xlookup-in-google-sheets-can-you-provide-an-example/
stats writer. "How can I use XLOOKUP in Google Sheets? Can you provide an example?." PSYCHOLOGICAL SCALES, 30 Jun. 2024, https://scales.arabpsychology.com/stats/how-can-i-use-xlookup-in-google-sheets-can-you-provide-an-example/.
stats writer. "How can I use XLOOKUP in Google Sheets? Can you provide an example?." PSYCHOLOGICAL SCALES, 2024. https://scales.arabpsychology.com/stats/how-can-i-use-xlookup-in-google-sheets-can-you-provide-an-example/.
stats writer (2024) 'How can I use XLOOKUP in Google Sheets? Can you provide an example?', PSYCHOLOGICAL SCALES. Available at: https://scales.arabpsychology.com/stats/how-can-i-use-xlookup-in-google-sheets-can-you-provide-an-example/.
[1] stats writer, "How can I use XLOOKUP in Google Sheets? Can you provide an example?," PSYCHOLOGICAL SCALES, vol. X, no. Y, ص Z-Z, June, 2024.
stats writer. How can I use XLOOKUP in Google Sheets? Can you provide an example?. PSYCHOLOGICAL SCALES. 2024;vol(issue):pages.
