PERCENTILE Function

The PERCENTILE function returns the k-th percentile of values in a dataset. Master percentile calculations with examples for statistical analysis.

ExcelExcel
Google SheetsGoogle Sheets
statistical
intermediate
Syntax Preview
ExcelExcelGoogle SheetsGoogle Sheets
=PERCENTILE(array, k)
What is the PERCENTILE Function?
Syntax and Parameters

Practical Examples

Calculate Student Test Score Percentiles

Find the 75th percentile score to identify top-performing students

Result: 87

Salary Benchmarking Analysis

Determine median and 90th percentile salaries for market comparison

Result: $125,500

Sales Performance Thresholds

Set quarterly sales targets based on historical performance percentiles

Result: $45,200

Website Response Time Analysis

Monitor 95th percentile response times for service level agreements

Result: 285

Income Distribution Analysis

Calculate multiple percentiles to understand economic distribution

Result: Dynamic based on percentile value in C2

Manufacturing Quality Control

Set acceptable product dimension tolerances using percentiles

Result: 10.15

Error Handling with PERCENTILE

Gracefully handle errors when calculating percentiles on filtered data

Result: Returns percentile or friendly error message

Common Errors and Solutions

#NUM!

The k value is not between 0 and 1

Cause:

The percentile parameter (k) must be a decimal between 0 and 1 inclusive. This error occurs when you enter a value like 75 instead of 0.75, or use a negative number or value greater than 1.

Solution:

1. Convert percentage to decimal by dividing by 100 (75% becomes 0.75) 2. Verify the k parameter cell contains a value between 0 and 1 3. Check for formula references that might calculate values outside this range 4. Use data validation on k parameter cells to restrict input to 0-1 range

Prevention:

Always express percentiles as decimals (0.25 for 25th percentile, 0.5 for median, 0.95 for 95th percentile). Consider adding a helper column that divides percentage inputs by 100 if users prefer percentage notation.

Frequency: 35%

Example:

#VALUE!

Array contains no numeric values or contains errors

Cause:

This error appears when the array parameter contains no valid numeric values, only text, logical values, blanks, or error values. PERCENTILE requires at least one numeric value to calculate a percentile.

Solution:

1. Verify your data range contains numeric values, not text that looks like numbers 2. Check for hidden error values (#N/A, #DIV/0!) within the array range 3. Use ISNUMBER() to identify which cells contain valid numeric data 4. Clean data with VALUE() or NUMBERVALUE() to convert text numbers to actual numbers 5. Remove or filter out error values before applying PERCENTILE

Prevention:

Always validate your data range before calculating percentiles. Use conditional formatting to highlight non-numeric cells, or implement data validation rules that ensure only numbers can be entered. For mixed-type data, use FILTER or array formulas to extract only numeric values.

Frequency: 25%

Example:

#N/A

Empty or insufficient data in array

Cause:

While less common with PERCENTILE than with lookup functions, #N/A errors can occur when using PERCENTILE with functions like FILTER that return empty arrays when no data matches the criteria.

Solution:

1. Wrap the formula in IFERROR to handle empty result scenarios 2. Add COUNTIF validation before calculating percentile to ensure sufficient data 3. Use IF statements to check if filtered results contain data: IF(COUNTA(range)>0, PERCENTILE(...), "No Data") 4. For dynamic ranges, verify the source data exists before applying filters

Prevention:

Implement defensive formula design by checking data availability first. For critical reports, add data validation warnings that alert users when insufficient data points exist for meaningful percentile calculations (generally at least 10-20 data points recommended for reliable percentiles).

Frequency: 20%

Example:

#REF!

Referenced range has been deleted or is invalid

Cause:

This error occurs when the array reference points to deleted cells, an invalid range, or when the workbook structure has changed (rows/columns deleted that were part of the PERCENTILE range).

Solution:

1. Check if the referenced range still exists in the worksheet 2. Use named ranges instead of direct cell references for better stability 3. Update the formula with the correct current range reference 4. If using references to other worksheets, verify the sheet names are correct 5. Recreate the formula if the reference is completely broken

Prevention:

Use structured references (Excel Tables) or named ranges that automatically adjust when data is added or removed. This makes formulas more resilient to worksheet changes. Avoid referencing entire columns (A:A) unless necessary, as this can cause issues when columns are restructured.

Frequency: 15%

Example:

Best Practices and Advanced Tips

Use PERCENTILE.INC vs PERCENTILE.EXC Appropriately

In Excel 2010 and later, PERCENTILE has been supplemented with PERCENTILE.INC (inclusive) and PERCENTILE.EXC (exclusive) functions. PERCENTILE.INC matches the classic PERCENTILE function and is generally preferred for most business applications. PERCENTILE.EXC uses a slightly different calculation method that excludes the endpoints (0 and 1 percentiles) and is preferred in some statistical contexts. For consistency across Excel versions and Google Sheets, stick with PERCENTILE or PERCENTILE.INC.

Combine with Conditional Formatting for Visual Analysis

Create dynamic dashboards by using PERCENTILE results as thresholds in conditional formatting rules. For example, highlight all values above the 90th percentile in green and below the 10th percentile in red. This instantly visualizes performance distribution and makes outliers obvious.

Calculate Multiple Percentiles Efficiently

When you need several percentiles (quartiles, deciles, or custom percentiles), create a helper table with percentile values (0.1, 0.25, 0.5, 0.75, 0.9) in one column and use PERCENTILE with an absolute reference to the data range. This allows quick calculation of a complete distribution profile and is easily maintained when data changes.

Minimum Data Points for Reliable Percentiles

While PERCENTILE technically works with just 2 data points, results become more statistically meaningful with larger datasets. For business decisions, aim for at least 30 data points for reliable percentile calculations. With very small datasets (under 10 points), percentile results can be misleading and simple MIN/MAX analysis might be more appropriate.

Performance Optimization for Large Datasets

When working with tens of thousands of rows, PERCENTILE can slow down your workbook if used in many cells. Consider calculating percentiles once in a summary area using named formulas or Power Query, then reference those results throughout your workbook. This is especially important for dashboards that refresh frequently.

Document Your Percentile Choices

When using percentiles for business decisions (setting targets, identifying outliers, defining thresholds), always document why you chose specific percentile values. The 90th percentile might be standard in your industry, but the 85th or 95th might be more appropriate for your specific context. This documentation helps with audits and ensures consistency across teams.

Combine with RANK for Individual Positioning

While PERCENTILE tells you the value at a certain percentile, combining it with RANK or PERCENTRANK helps you understand where individual data points fall within the distribution. Use PERCENTILE to set thresholds, then use PERCENTRANK to see where each value ranks percentile-wise.

PERCENTILE vs Related Functions
Frequently Asked Questions

Need Help with PERCENTILE Function?

Stop struggling with formula syntax. Use AskFormulas to generate validated formulas instantly with our AI-powered tool.

Example Excel formula:

Related Formulas

AVERAGE Function Guide

Master the AVERAGE function with practical examples and error solutions. Learn to calculate mean values and analyze data efficiently in Excel and Sheets.

beginner
statistical
ExcelExcel
Google SheetsSheets
Validated
MAX Function - Excel & Sheets

Master the MAX function to find the largest value in your data. Learn syntax, examples, error handling, and best practices for Excel and Google Sheets.

beginner
math
ExcelExcel
Google SheetsSheets
Validated
MEDIAN Function in Excel

Master the MEDIAN function to find the middle value in datasets. Learn syntax, practical examples, and error solutions for statistical analysis.

intermediate
statistical
ExcelExcel
Google SheetsSheets
Validated
STDEV.S Function in Excel

Calculate sample standard deviation in Excel with STDEV.S. Learn syntax, examples, and solutions to common errors for statistical analysis in spreadsheets.

intermediate
statistical
ExcelExcel
Google SheetsSheets
Validated