The Excel RANK function returns the rank of a number within a list of numbers. It is a legacy name — Microsoft now recommends RANK.EQ, which behaves identically (ties share the top rank).
Syntax
| Argument | Description | |
|---|---|---|
number | Required | The value whose rank you want. |
ref | Required | The array or range of numbers to rank against. Non-numeric values are ignored. |
order | Optional | 0 or omitted = descending (largest ranks 1); any non-zero value = ascending (smallest ranks 1). |
How to use it
RANK reports the position of a value within a list. By default the largest number is rank 1 (descending).
Ties receive the same rank, and that rank equals the best (top) position of the tied group — so two values tied for 2nd both get rank 2, and the next value is rank 4 (3 is skipped).
Use the modern names: RANK.EQ reproduces RANK exactly (ties share the top rank), while RANK.AVG gives tied values the average of their positions. Prefer one of these in new workbooks.
Try it: interactive demo
Pick a RANK example to see the formula and its result.
Practice workbook
Frequently asked questions
Is RANK the same as RANK.EQ?
RANK.EQ (Excel 2010+) uses the same tie-handling (tied values share the top rank) and returns identical results. RANK.AVG is a newer alternative that averages tied positions.How are ties handled?
How do I rank smallest-to-largest?
order argument to a non-zero value (e.g. 1). Then the smallest number ranks 1.Should I switch to RANK.EQ?
Master functions like this in one day
This page covers one function. Our Excel Formulas and Functions class covers the 30 that matter most — live, hands-on, taught by professionals in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or online.
See the Formulas & Functions Class