Excel LOOKUP function
The Microsoft Excel LOOKUP function finds certain value in a one column or one row range, and return the corresponding value from another (one row or one column) range.
Tips: To lookup values, it is more recommended to use the VLOOKUP/HLOOKUP function and the new XLOOKUP function, because the LOOKUP function has more limitations in the calculation. Use the VLOOKUP/HLOOKUP function or the XLOOKUP function, depending on the Excel version you are using.
- VLOOKUP function: It performs a vertical lookup. Find things in a table or a range by row. It is available in Excel 2007 to 2021, and Excel for Microsoft 365.
- HLOOKUP function: It performs a horizontal lookup. Find things in the top row of a table or an array of values by column. It is available in Excel 2007 to 2021, and Excel for Microsoft 365.
- XLOOKUP function: The XLOOKUP function is the new lookup function that solves a lot of the issues that VLOOKUP and HLOOKUP had. It finds things in a table or a range in any direction (up, down, left, right), which is more easier to use and works faster than other lookup functions. It is only available in Excel for Microsoft 365.
The LOOKUP function will return a value in a one column range.
1. If the lookup number is smaller than all values in the lookup range, it will return a #N/A error value.
2. LOOKUP works based on approximate match, if the lookup value can’t be found exactly, it will match the next smallest value.
3. If there are multiple matched look_up values, it will match the last value.
4. The LOOKUP function is not case-sensitive.
Example 1: Use LOOKUP function to find a value with one criterion
As the below screenshot shown, you need to find Peach in the table range, and return the corresponding result in the Mon column, you can achieve it as follows.
Select a blank cell, copy the below formula into it and press the Enter key.
- H4 is the reference cell containing the search value “Peach”; B3:E8 is the lookup range containing the search value and the result value; D3:D8 is the result value range.
- You can replace the H4 with "Peach" or B5 directly as you need.
Example 2: LOOKUP function search for a value with multiple criteria
As below screenshot shown, there are duplicate names in different departments. For finding the position of a specific person (says Fred Schuler), you need to match the Name and Department criteria at the same time. Please do as follows.
1. Select blank cell to place the result, copy the below formula into it and press the Enter key.
- In the formula, B2:B8 and C2:C8 are the column ranges containing the first and second look up values; F4 and G4 are the references to the cells containing the two criteria; D2:D8 is the result value range. Please change them based on your table range.
- This formula can also help.