Table of Contents
The RANK IF formula in Excel is a useful tool for identifying the rank of a specific value within a given range. To use this formula, the user must first specify the range of values and the criteria that determine the ranking. The formula will then calculate the position of the desired value in the range, based on the specified criteria. This allows for easy identification of the highest or lowest values in a data set, and can be useful in various data analysis and decision-making processes. Overall, the RANK IF formula is a powerful tool for efficiently organizing and analyzing data in Excel.
Use a RANK IF Formula in Excel
You can use the following methods to create a RANK IF formula in Excel:
Method 1: RANK IF
=COUNTIFS($A$2:$A$11,A2,$B$2:$B$11,">"&B2)+1
This formula finds the rank of the value in cell B2 among all values in the range B2:B11 where the corresponding value in the range A2:A11 is equal to the value in cell A2.
Using this method, the largest value is assigned a value of 1.
Method 2: Reverse RANK IF
=COUNTIFS($A$2:$A$11,A2,$B$2:$B$11,"<"&B2)+1
This formula finds the rank of the value in cell B2 among all values in the range B2:B11 where the corresponding value in the range A2:A11 is equal to the value in cell A2.
Using this method, the smallest value is assigned a value of 1.
The following examples show how to use each method with the following dataset in Excel:

Example 1: RANK IF
We can type the following formula into cell C2 to calculate the rank of the points value in cell B2 among all players on the “Mavs” team:
=COUNTIFS($A$2:$A$11,A2,$B$2:$B$11,">"&B2)+1We can then drag this formula down to each remaining cell in column C:

Here’s how to interpret the output:
- The first player scored the 3rd most points among all players on the Mavs team.
- The second player scored the 5th most points among all players on the Mavs team.
And so on.
Using this formula, the player with the highest points value on each team receives a rank of 1.
Example 2: Reverse RANK IF
We can type the following formula into cell C2 to calculate the rank of the points value in cell B2 among all players on the “Mavs” team:
=COUNTIFS($A$2:$A$11,A2,$B$2:$B$11,"<"&B2)+1We can then drag this formula down to each remaining cell in column C:

Here’s how to interpret the output:
- The first player scored the 3rd lowest points among all players on the Mavs team.
- The second player scored the 1st lowest points among all players on the Mavs team.
And so on.
Using this formula, the player with the lowest points value on each team receives a rank of 1.
The following tutorials explain how to perform other common tasks in Excel:
Cite this article
stats writer (2024). How do you use a RANK IF formula in Excel?. PSYCHOLOGICAL SCALES. Retrieved from https://scales.arabpsychology.com/stats/how-do-you-use-a-rank-if-formula-in-excel/
stats writer. "How do you use a RANK IF formula in Excel?." PSYCHOLOGICAL SCALES, 27 Jun. 2024, https://scales.arabpsychology.com/stats/how-do-you-use-a-rank-if-formula-in-excel/.
stats writer. "How do you use a RANK IF formula in Excel?." PSYCHOLOGICAL SCALES, 2024. https://scales.arabpsychology.com/stats/how-do-you-use-a-rank-if-formula-in-excel/.
stats writer (2024) 'How do you use a RANK IF formula in Excel?', PSYCHOLOGICAL SCALES. Available at: https://scales.arabpsychology.com/stats/how-do-you-use-a-rank-if-formula-in-excel/.
[1] stats writer, "How do you use a RANK IF formula in Excel?," PSYCHOLOGICAL SCALES, vol. X, no. Y, ص Z-Z, June, 2024.
stats writer. How do you use a RANK IF formula in Excel?. PSYCHOLOGICAL SCALES. 2024;vol(issue):pages.
