
LookupLevel: IntermediateAvailable in: Excel 365 / 2021+
In this article
- Syntax
- Examples
- Example 1
- Example 2
- Related functions
XMATCH returns the position of an item, defaulting to exact match, and can search from the end or use wildcards.
Syntax
=XMATCH(lookup_value, lookup_array, [match_mode], [search_mode])
| Argument |
What it means |
match_mode |
0 exact (default), −1/1 next smaller/larger, 2 wildcard. |
search_mode |
1 first-to-last, −1 last-to-first. |
Examples
Example 1
=XMATCH("Mar", B1:M1)
Column position of March.
Example 2
=XMATCH(F2, A:A, 0, -1)
Position of the last occurrence.
MATCH · XLOOKUP · INDEX
📚 Part of the free Excel course: Beginner → Expert · Try it in the Formula Lab or ask the AI Helper.
✨ Ask AI about this articleStuck on a step? Ask a question and the AI answers using this article.
Free · AI can be wrong