Free online range and IQR calculator
The interquartile range (IQR) is the spread of the middle 50% of your data. This calculator also finds the range, quartiles, and any outliers using the Tukey fences method.
How to use
- Type or paste at least 4 numbers into the text box — commas, spaces, or semicolons all work.
- Q1, median, Q3, IQR, and outliers appear instantly.
- The sorted data set is shown at the bottom for reference.
- Click “Share with my numbers” to copy a URL that restores your data.
Formulas
Range = Max − Min
Q1 = median of the lower half of the sorted data
Q2 = median of the full data set
Q3 = median of the upper half of the sorted data
IQR = Q3 − Q1
Lower fence = Q1 − 1.5 × IQR
Upper fence = Q3 + 1.5 × IQR
Values outside the fences are flagged as outliers.
Worked example
Data: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 (n = 10, even)
- Sorted: 1, 2, 3, 4, 5 | 6, 7, 8, 9, 10
- Q1 = median of [1,2,3,4,5] = 3
- Q2 (median) = (5+6)/2 = 5.5
- Q3 = median of [6,7,8,9,10] = 8
- IQR = 8 − 3 = 5
- Fences: lower = 3 − 7.5 = −4.5; upper = 8 + 7.5 = 15.5 → no outliers
Notes
- This calculator uses the exclusive (Tukey) quartile method, also called Method 1.
- Different statistical software may use inclusive quartiles, giving slightly different Q1/Q3 values.
- At least 4 numbers are required to compute meaningful quartiles.
Frequently asked
What is the IQR?
The interquartile range (IQR) is Q3 minus Q1 — the spread of the middle 50% of values. It is resistant to outliers, unlike the full range.
How are quartiles calculated?
This calculator uses the exclusive (Tukey) method. For odd-count data sets, the median is excluded when splitting the data into lower and upper halves. Q1 is the median of the lower half; Q3 is the median of the upper half.
How are outliers detected?
A value is an outlier if it falls below Q1 − 1.5 × IQR or above Q3 + 1.5 × IQR. These boundaries are called Tukey fences.
Why does the calculator need at least 4 numbers?
Four values are the minimum needed to split the data into two meaningful halves and compute Q1 and Q3.
What is the difference between range and IQR?
The range is simply max minus min, so a single extreme value inflates it. The IQR only spans the middle 50%, so it is a more robust measure of spread.
Related calculators
- Variance calculator
Population or sample variance, standard deviation, mean, and mode.
- Standard deviation calculator
Population σ and sample s standard deviation for any list of numbers.
- Average calculator
Mean, median, mode, range, min, max, and sum for any list of numbers.
- Percentage calculator
Find a percentage of a number, or work backwards to the whole.