Excel XMATCH function
Returns the position of a value in a list. It is the modern version of MATCH. In Spanish Excel it is called COINCIDIRX.
Syntax
English Excel
=XMATCH(lookup_value, lookup_array, [match_mode], [search_mode])
Spanish Excel (Mexico)
=COINCIDIRX(valor_buscado, matriz_buscada, [modo_de_coincidencia], [modo_de_búsqueda])
Spanish Excel (Spain, Latin America)
=COINCIDIRX(valor_buscado; matriz_buscada; [modo_de_coincidencia]; [modo_de_búsqueda])
| Argument | What it is |
|---|---|
| lookup_value | What you are looking for. |
| lookup_array | The row or column to search. |
| match_modeoptional | 0 exact (default), -1 exact or next smaller, 1 exact or next larger. |
| search_modeoptional | 1 from the start, -1 from the end. |
Example
XMATCH(value, list) returns the position of a value, with an exact match by default. A fourth argument of -1 searches from the end, to find the last time it appears.
=XMATCH(D2,B2:B9)
Common mistake
Unlike MATCH, exact match is the default: there is no need to type 0.
About Ads
This site uses Google AdSense to display ads. These ads help us keep WebHerramientas completely free. Ads are managed by Google and meet strict security and privacy standards.
Ads help us keep WebHerramientas free for everyone
Practice XMATCH
Type the formula in the sheet and check it instantly. Spanish or English function names both work. See all lessons
Position with XMATCH
XMATCH(value, list) returns the position of a value, with an exact match by default. A fourth argument of -1 searches from the end, to find the last time it appears.
In E2, find the turn in which the customer in D2 first came.
| A | B | C | D | E | F | G | |
|---|---|---|---|---|---|---|---|
| 1 | Turn | Customer | Customer | First visit | Last visit | ||
| 2 | 1 | Ana | Luis | ||||
| 3 | 2 | Luis | |||||
| 4 | 3 | Ana | |||||
| 5 | 4 | Sofía | |||||
| 6 | 5 | Diego | |||||
| 7 | 6 | Luis | |||||
| 8 | 7 | Ana | |||||
| 9 | 8 | Marta | |||||
| 10 |
Tip: while typing, click a cell or drag across several to insert their reference. F4 anchors the reference with $.
Frequently asked questions
- What is XMATCH called in Spanish?
- In Spanish Excel it is COINCIDIRX. The formula =XMATCH(D2,B2:B9) is written =COINCIDIRX(D2;B2:B9) (or with commas in Mexico).
- Why does XMATCH use semicolons in some Excel versions?
- It depends on regional settings. Where the comma is the decimal mark (Spain, much of South America), Excel separates arguments with semicolons. English Excel and Mexican Spanish Excel use commas.
- What is the most common XMATCH mistake?
- Unlike MATCH, exact match is the default: there is no need to type 0.