ShareYourGroupShareYourGroupExcel Formulas

Lookup functions

MATCH function in Excel

MATCH returns the position of a value in a row or column.

MATCH does not return a value from your data. It returns a position: "the thing you asked for is the 4th item in this list". That number is rarely the final answer. It is what other functions need, above all INDEX.

Syntax

=MATCH(lookup_value, lookup_array, [match_type])
ArgumentWhat it is
lookup_valueThe value to look for.
lookup_arrayA single row or a single column to search.
match_type0 for an exact match. 1 (the default) for the largest value not more than the lookup value, in a range sorted upwards. -1 for the smallest value not less, in a range sorted downwards.

Examples

Each result below is what Excel itself showed for the formula on the sample sheet.

Sample sheet: A small price list with item codes. The table is sorted by code.
ABCDE
1CodeItemCategoryPriceStock
2A101Basmati Rice 5 kgGrocery65040
3A102Toor Dal 1 kgGrocery16075
4B201NotebookStationery60300
5B202Ball PenStationery100
6C301LED BulbElectronics110200
7C302Power BankElectronics129918
8D401Steel BottleHome45055
Sample sheet: A marks table and a grade table. The grade table lists the lowest mark of each grade, in rising order.
ABCDE
1NameMarksFromGrade
2Asha910E
3Ravi4533D
4Meena7950C
5Kabir2865B
6Tara6580A

How it works

MATCH goes through a single row or column and reports where the lookup value sits, counting from the start of the range. If the range starts at A2, the first cell is position 1, even though it is in row 2 of the sheet.

The match type

match_typeWhat it findsThe range must be
0the first exact matchin any order
1 or left outthe largest value less than or equal to the lookup valuesorted smallest to largest
-1the smallest value greater than or equal to the lookup valuesorted largest to smallest

Type the 0. The default is 1, an approximate match, and on an unsorted list it returns a wrong position without warning. This is the same trap as VLOOKUP's last argument.

What MATCH is used for

Wildcards

With match type 0, a question mark stands for any one character and a star for any run of characters. "A*" finds the first entry that starts with A. To search for a real star or question mark, put a tilde in front: "~*".

Common mistakes

MATCH ignores the difference between capital and small letters.

In Google Sheets

MATCH is the same in Google Sheets.

Related functions

Every result on this page was calculated in Microsoft Excel (version 16.0, build 20326) on 12 November 2026, not typed by hand.

This is an independent help site. It is not connected with or approved by Microsoft. Excel and Microsoft 365 are trademarks of Microsoft Corporation, named here only to say which program a formula is for. The people and figures in the sample sheets are made up.