PERCENTILE & QUARTILE: Calculate Rank‑Based Metrics Like a Pro

PERCENTILE & QUARTILE_ Calculate Rank‑Based Metrics Like a Pro
Master Excel’s PERCENTILE.INC, PERCENTILE.EXC, QUARTILE.INC, PERCENTRANK, and RANK.EQ functions. This tutorial blog covers eight practical examples covering performance banding, salary analysis, outlier detection, grading curves, and executive dashboards.

Average and median tell you the centre of a dataset. They say nothing about where any individual value sits relative to everyone else. Rank-based metrics fill that gap. They answer a different and often more useful question: not "what is typical?" but "where does this value rank?" A sales figure is not just a number — it is top 10%, bottom quartile, or 73rd percentile. PERCENTILE and QUARTILE functions give you those answers directly in Excel.

This guide covers the complete PERCENTILE and QUARTILE function family — PERCENTILE.INC, PERCENTILE.EXC, QUARTILE.INC, QUARTILE.EXC, and PERCENTRANK.INC — and the RANK function for whole-number ranking. Eight practical examples show how to use them for performance banding, outlier detection, compensation analysis, grading curves, and executive dashboards. By the end, you will know exactly which function to reach for in any ranking scenario.

Availability: All functions in this guide are available in Excel 2010 and all later versions, including Microsoft 365, Excel 2024, 2021, 2019, and 2016. They also work in Google Sheets. The legacy PERCENTILE, QUARTILE, and RANK functions remain available but PERCENTILE.INC, QUARTILE.INC, and RANK.EQ are the recommended modern equivalents.

What Are Percentiles and Quartiles?

A percentile tells you the value below which a given percentage of observations fall. Specifically, the 90th percentile is the value below which 90% of the data sits. Quartiles are percentiles at fixed intervals. Specifically, Q1 is the 25th percentile, Q2 is the 50th percentile (the median), and Q3 is the 75th. Together, Q1 and Q3 define the interquartile range (IQR) — the spread of the middle 50% of the data.

PERCENTRANK is the inverse operation. Essentially, it flips the question around. Instead of asking what value sits at the 90th percentile, it answers the reverse: at what percentile does this value sit? Both operations are essential for ranking work. PERCENTILE returns a value given a rank. PERCENTRANK returns a rank given a value.

What Functions Are in the PERCENTILE and QUARTILE Family?

FunctionWhat it returnsKey constraintReplaces
PERCENTILE.INCValue at a given percentile (0 to 1 inclusive)k can be 0 or 1 (min/max)Legacy PERCENTILE
PERCENTILE.EXCValue at a given percentile (exclusive of 0 and 1)k must be strictly between 0 and 1No legacy equivalent
QUARTILE.INCQuartile value (quart 0–4 inclusive)quart 0 = min, 4 = maxLegacy QUARTILE
QUARTILE.EXCQuartile value (quart 1–3 exclusive)quart 0 or 4 returns #NUM!No legacy equivalent
PERCENTRANK.INCPercentile rank of a value (0 to 1 inclusive)Returns 0 for min, 1 for maxLegacy PERCENTRANK
PERCENTRANK.EXCPercentile rank of a value (exclusive)Never returns exactly 0 or 1No legacy equivalent
RANK.EQWhole-number rank of a value in a listTies receive the same rankLegacy RANK

What Is the Syntax for Each Function?

=PERCENTILE.INC(array, k) =PERCENTILE.EXC(array, k) =QUARTILE.INC(array, quart) =QUARTILE.EXC(array, quart) =PERCENTRANK.INC(array, x, [significance]) =RANK.EQ(number, ref, [order])
ArgumentFunctionWhat it does
array / refAllThe range of numeric values to rank against. Text and empty cells are ignored.
kPERCENTILE.INC / EXCThe percentile as a decimal: 0.25 = 25th percentile, 0.9 = 90th percentile. INC accepts 0 and 1. EXC requires strictly between 0 and 1.
quartQUARTILE.INC / EXCInteger 0–4 for INC (0=min, 1=Q1, 2=median, 3=Q3, 4=max). Integer 1–3 for EXC — 0 and 4 return #NUM!.
xPERCENTRANK.INC / EXCThe specific value whose percentile rank you want to find. Need not be in the array.
significancePERCENTRANK.INC / EXCOptional. Number of decimal places in the result. Default is 3 (e.g. 0.857).
orderRANK.EQ0 = rank largest as 1 (descending, default). 1 = rank smallest as 1 (ascending).

Examples 1–4: Core Ranking Operations

1
PERCENTILE.INC — find the value at any percentile cut

PERCENTILE.INC answers one question: what value marks the Nth percentile in my dataset? It is the most frequently used ranking function. It is ideal for setting performance thresholds, pay band boundaries, and benchmark targets. The k argument is a decimal between 0 and 1 — so the 90th percentile is k = 0.90.

Scores
P10
P50 (median)
P90
P99
A2:A100
42
67
88
98
Find the value at common percentile thresholds. Scores in A2:A100. k is a decimal fraction: 0.10 = 10th percentile. 10th percentile — bottom decile threshold: =PERCENTILE.INC(A2:A100, 0.10) → 42 50th percentile — median (same as MEDIAN function): =PERCENTILE.INC(A2:A100, 0.50) → 67 90th percentile — high-performer threshold: =PERCENTILE.INC(A2:A100, 0.90) → 88 PERCENTILE.INC(data, 0.25) = QUARTILE.INC(data, 1) — always identical. Use whichever is clearer for your context. =PERCENTILE.INC(A2:A100, 0.25) = =QUARTILE.INC(A2:A100, 1) → TRUE (always)
2
PERCENTRANK.INC — find where a value sits in the distribution

PERCENTRANK.INC is the inverse of PERCENTILE.INC. It answers "at what percentile does this specific value rank?" The result is a decimal between 0 and 1. Multiply by 100 to get a whole-number percentile. It is specifically useful for individual scorecards, league table positions, and peer comparison reports.

Value
PERCENTRANK.INC
As percentage
Interpretation
Score = 88
0.900
90th
Top 10%
Score = 50
0.350
35th
Below median
PERCENTRANK.INC returns the percentile rank of value x in the dataset. A2:A100 = full dataset. x = value to rank (can be any number, not just one in the array). Find the percentile rank of score 88: =PERCENTRANK.INC(A2:A100, 88) → 0.9 (i.e., 88 ranks at the 90th percentile) Convert to a readable percentage — multiply by 100: =PERCENTRANK.INC(A2:A100, 88) * 100 → 90 (display as "90th percentile") Build a label for a scorecard — "You are at the 90th percentile": TEXT formats the decimal. ROUND removes floating-point noise. "You are at the " & ROUND(=PERCENTRANK.INC($A$2:$A$100, B2) * 100, 0) & "th percentile" → "You are at the 90th percentile"
3
RANK.EQ — whole-number rank in a list

PERCENTRANK returns a fractional percentile. RANK.EQ returns a whole-number position: 1st, 2nd, 3rd. This is the right function when your audience expects ordinal ranks — sports league tables, sales leaderboards, and student rankings all communicate better with positions than with percentile decimals. Ties receive the same rank; the next rank is skipped.

Name
Score
Rank (high=1)
Rank (low=1)
Alice
92
1
5
Bob
78
2
4
Carol
65
3
3
Dan
65
3
3
Eve
41
5
1
B2 = score to rank. $B$2:$B$6 = full score column (absolute ref for copy-down). order = 0: largest value = rank 1 (typical for scores/sales). order = 1: smallest value = rank 1 (useful for times, error rates). Rank from highest to lowest (score of 92 = rank 1): =RANK.EQ(B2, $B$2:$B$6, 0) → 1 for Alice (92), 2 for Bob (78), 3 for Carol and Dan (both 65) Rank from lowest to highest (shortest time = rank 1): =RANK.EQ(B2, $B$2:$B$6, 1) Add "of N" for context — "3 of 5" is more readable than just "3": =RANK.EQ(B2, $B$2:$B$6, 0) & " of " & COUNTA($B$2:$B$6) → "1 of 5" for Alice
4
IQR and outlier fences — QUARTILE.INC with the 1.5×IQR rule

The interquartile range (IQR) is Q3 minus Q1. The standard outlier rule flags values below Q1 − 1.5×IQR or above Q3 + 1.5×IQR. Store Q1, Q3, and IQR in named cells. This avoids recalculating those values repeatedly and keeps the outlier flag formula readable.

Cell
Formula
Result
D2 (Q1)
=QUARTILE.INC(A2:A100, 1)
25
D3 (Q3)
=QUARTILE.INC(A2:A100, 3)
75
D4 (IQR)
=D3-D2
50
D5 (lower fence)
=D2 - 1.5*D4
−50
D6 (upper fence)
=D3 + 1.5*D4
150
Flag each row as Outlier or Normal. B2 = value to check. $D$5 = lower fence. $D$6 = upper fence. =IF(OR(B2<$D$5, B2>$D$6), "Outlier", "Normal") Count how many outliers exist in the full dataset: =COUNTIF(C2:C100, "Outlier") Alternative — count outliers without a helper column: SUMPRODUCT evaluates the condition row by row and sums the TRUE results. =SUMPRODUCT(--(OR(A2:A100<$D$5) +(A2:A100>$D$6)>0))

Examples 5–8: Applied Scenarios

Performance Banding, Compensation, and Dashboards

5
Performance banding — classify each score into a tier

Performance reviews often use three or four tiers: Needs Improvement, Developing, Proficient, and Exceptional. Defining those bands using PERCENTILE.INC makes them data-driven and self-updating. As new scores are added to the dataset, the thresholds adjust automatically — no manual recalculation required.

Scores in A2:A200. B2 = score to classify. Define thresholds using PERCENTILE.INC on the full score range. Thresholds are data-driven — they update automatically as data changes. Pre-calculate thresholds in named cells for clarity: E2 = P25 threshold = PERCENTILE.INC($A$2:$A$200, 0.25) E3 = P50 threshold = PERCENTILE.INC($A$2:$A$200, 0.50) E4 = P75 threshold = PERCENTILE.INC($A$2:$A$200, 0.75) Classify each score row: =IF(B2 <= $E$2, "Needs Improvement", IF(B2 <= $E$3, "Developing", IF(B2 <= $E$4, "Proficient", "Exceptional"))) → Each row receives a band label automatically Count employees in each band — for a distribution summary: C2:C200 holds the band labels. =COUNTIF(C2:C200, "Exceptional")
6
Compensation analysis — salary quartile bands and pay equity

Salary analysis uses quartile bands to assess pay equity. Specifically, comparing an individual's salary to the Q1 and Q3 of their job grade tells you whether they are at risk of leaving (below Q1) or paid above market (above Q3). Additionally, the midpoint — Q2 — is a common target for competitive market positioning.

A2:A300 = all salaries for the job grade (the benchmark population). B2 = salary of the individual employee to evaluate. Calculate the quartile thresholds for this grade: D2 = Q1: =QUARTILE.INC($A$2:$A$300, 1) D3 = Q2: =QUARTILE.INC($A$2:$A$300, 2) D4 = Q3: =QUARTILE.INC($A$2:$A$300, 3) Classify the employee's salary position in the grade: =IF(B2 < $D$2, "Below Q1 — underpaid risk", IF(B2 <= $D$3, "Q1–Q2 range", IF(B2 <= $D$4, "Q2–Q3 range", "Above Q3 — above market"))) Compa-ratio — salary as a percentage of the grade midpoint: A compa-ratio of 1.0 means the salary equals the Q2 midpoint exactly. B2 / $D$3 → 0.95 means the salary is 95% of the grade midpoint
7
Grading on a curve — assign letter grades using percentile thresholds

Norm-referenced grading assigns letter grades based on where students rank relative to their cohort — not against a fixed score scale. The top 10% receive an A. The next 25% receive a B. The middle 30% receive a C, and so on. PERCENTILE.INC calculates the score thresholds automatically for any cohort size.

Student scores in A2:A60. B2 = individual score to grade. Norm-referenced grading — grade reflects rank, not absolute score. Pre-calculate grade thresholds (calculate once, reference everywhere): E2 = C/D boundary = PERCENTILE.INC($A$2:$A$60, 0.30) E3 = B/C boundary = PERCENTILE.INC($A$2:$A$60, 0.60) E4 = A/B boundary = PERCENTILE.INC($A$2:$A$60, 0.85) E5 = A+/A boundary = PERCENTILE.INC($A$2:$A$60, 0.95) Assign letter grade based on the score in B2: =IF(B2 >= $E$5, "A+", IF(B2 >= $E$4, "A", IF(B2 >= $E$3, "B", IF(B2 >= $E$2, "C", "D")))) Show each student's percentile rank alongside their grade: PERCENTRANK.INC returns the rank as a decimal — multiply by 100 for percentage. =ROUND(=PERCENTRANK.INC($A$2:$A$60, B2) * 100, 0) & "th percentile"
8
Executive dashboard — decile table and dynamic ranking summary

Executive dashboards often need a complete distributional summary alongside individual performance cards. A decile table — showing the value at every 10th percentile from P10 to P90 — gives a full picture of the distribution in nine rows. Pairing it with PERCENTRANK and RANK.EQ for the featured metric also creates a self-contained ranking summary that updates as data changes.

Build a decile table — enter in a column, one row per decile. Revenue data in A2:A500. Each formula uses a different k value. D2 = P10: =PERCENTILE.INC($A$2:$A$500, 0.10) D3 = P20: =PERCENTILE.INC($A$2:$A$500, 0.20) D4 = P30: =PERCENTILE.INC($A$2:$A$500, 0.30) ... continue through ... D10 = P90: =PERCENTILE.INC($A$2:$A$500, 0.90) Parametric version — use the row number to drive the k value: Place in D2 and copy down 9 rows. C2 = 10, C3 = 20 ... C10 = 90. =PERCENTILE.INC($A$2:$A$500, C2/100) Dashboard KPI card — show rank, percentile, and quartile for one key metric: B2 = the featured metric value (e.g. this month's revenue). Rank position: =RANK.EQ(B2, $A$2:$A$500, 0) & " of " & COUNT($A$2:$A$500) Percentile position: =ROUND(=PERCENTRANK.INC($A$2:$A$500, B2) * 100, 0) & "th percentile" Quartile band: =CHOOSE(MATCH(TRUE, B2<={=QUARTILE.INC($A$2:$A$500,1),=QUARTILE.INC($A$2:$A$500,2),=QUARTILE.INC($A$2:$A$500,3),1E99},0), "Q1","Q2","Q3","Q4") → "Q4" for a value above the 75th percentile
Pre-calculating PERCENTILE thresholds in static cells — rather than embedding them in every row formula — reduces calculation load significantly on large datasets. Reference the threshold cells in your IF and MATCH formulas instead of calling PERCENTILE.INC repeatedly per row.

Common Issues and How to Fix Them

PERCENTILE.EXC returns #NUM!

PERCENTILE.EXC requires k to be strictly between 0 and 1 — it returns #NUM! for k = 0 or k = 1 exactly. It also returns #NUM! when the dataset has too few values for the requested percentile. On small datasets with k very close to 0 or 1 (such as 0.01 or 0.99), switch to PERCENTILE.INC instead. It handles those boundary positions without error.

PERCENTRANK gives an unexpected decimal

PERCENTRANK.INC returns a value between 0 and 1, not a whole-number percentage. Multiply by 100 and wrap in ROUND to get a clean integer: =ROUND(PERCENTRANK.INC(A:A, B2)*100, 0). The result also depends on every value in the reference array — adding or removing data changes all PERCENTRANK results. For a stable rank that does not shift with new data, use RANK.EQ instead.

RANK.EQ produces gaps after tied values

When two values tie for rank 3, RANK.EQ assigns both rank 3 and skips rank 4 — the next value is rank 5. This is statistically correct but can surprise audiences expecting consecutive numbers. If you need a dense ranking with no gaps — where ties share a rank but the next rank is not skipped — use COUNTIF instead: =COUNTIF($B$2:$B$100,">"&B2)+1 for a descending dense rank.

INC vs EXC — choose one and use it consistently: PERCENTILE.INC and PERCENTILE.EXC return different values for the same k on the same data. Mixing INC and EXC within the same analysis — for example, using INC for the 25th percentile threshold and EXC for the 90th — produces results that match neither standard method. Pick one approach and apply it throughout the entire report.

Frequently Asked Questions

  • What is the difference between PERCENTILE.INC and PERCENTILE.EXC?+
    Both functions find the value at a given percentile position, but they use different interpolation methods. PERCENTILE.INC treats k = 0 as the dataset minimum and k = 1 as the maximum, including those boundary values in the calculation. PERCENTILE.EXC excludes those boundaries — k must be strictly between 0 and 1. As a result, PERCENTILE.EXC returns a slightly lower value at the same k for most datasets. PERCENTILE.INC matches R, Python, and Google Sheets by default. PERCENTILE.EXC matches TI-84 calculators and many academic textbooks. Use INC for most business work.
  • What is the difference between PERCENTILE and PERCENTRANK?+
    They are inverse operations. PERCENTILE takes a percentile position (k = 0.90) and returns the corresponding value. PERCENTRANK takes a specific value (x = 88) and returns its percentile position (0.90). Use PERCENTILE when you want to know "what value is at the 90th percentile?" Use PERCENTRANK when you want to know "at what percentile does this specific value sit?"
  • What is the difference between RANK.EQ and RANK.AVG?+
    Both functions rank a value in a list. When there are no ties, they return identical results. The difference appears only on tied values. RANK.EQ assigns the same rank to all tied values (the lowest rank in the group), then skips the next ranks. RANK.AVG assigns the average of the ranks those tied values would have occupied. For example, two values tied for ranks 3 and 4 both receive rank 3.5 from RANK.AVG and rank 3 from RANK.EQ. Use RANK.EQ for leaderboards and ordinal rankings. Use RANK.AVG for statistical analysis where average tied ranks are needed.

More Ranking Questions

  • How do PERCENTILE and QUARTILE relate to each other?+
    Quartiles are percentiles at fixed positions. QUARTILE.INC(data, 1) always returns the same value as PERCENTILE.INC(data, 0.25). Similarly, QUARTILE.INC(data, 3) equals PERCENTILE.INC(data, 0.75). QUARTILE is a convenient shorthand for the specific percentile cuts at 25%, 50%, and 75%. For any other percentile position — the 10th, 33rd, 90th, or any non-quartile value — use PERCENTILE.INC or PERCENTILE.EXC directly.
  • Can PERCENTRANK return a value outside 0 to 1?+
    No. PERCENTRANK.INC always returns a value between 0 and 1 inclusive. It returns 0 for the minimum value in the array and 1 for the maximum. PERCENTRANK.EXC never returns exactly 0 or 1 — it returns a value strictly between those bounds. If you supply an x value that is outside the range of the array (below the minimum or above the maximum), PERCENTRANK returns #N/A because the value is outside the known data range.
  • How do I create a dense rank with no gaps after ties?+
    RANK.EQ skips ranks after ties — two values at rank 3 make the next value rank 5. To produce a dense rank where ties share a position and the next rank immediately follows, use COUNTIF: for a descending dense rank, =COUNTIF($B$2:$B$100,">"&B2)+1. For an ascending dense rank, =COUNTIF($B$2:$B$100,"<"&B2)+1. This approach never skips a rank number regardless of how many ties exist.