Quartiles & IQR Calculator
Calculate the quartiles and interquartile range of a list of numbers.
Median (Q2)
- Q1 (lower quartile)
- Q3 (upper quartile)
- IQR
- Minimum
- Maximum
- Range
How we calculated this
Xiliro uses the "median of halves" method: sort the values, find the overall median, then find the median of the lower half (Q1) and the median of the upper half (Q3), leaving the middle value out of both halves when the count is odd. IQR = Q3 − Q1. Other quartile conventions exist and can give slightly different values for the same data.
Sorted values
Worked example
For 1, 2, 3, 4, 5, 6, 7, 8, 9: Q1 is 2.5, the median is 5, Q3 is 7.5, and the IQR is 5.
How it works
This tool splits your sorted numbers into four equal parts. It uses the "median of halves" method commonly taught in UK schools: find the overall median, then find the median of the lower half (Q1) and the median of the upper half (Q3), leaving the middle value out of both halves when there is an odd number of values. The interquartile range (IQR) is Q3 minus Q1. Other quartile conventions exist (for example, some spreadsheet software uses a different, interpolation-based method) and can give slightly different Q1/Q3 values for the same data. This is a genuine difference between methods, not an error. At least 2 numbers are needed, since a single number has no meaningful upper or lower half.
What this result means
Q1 and Q3 mark the boundaries of the middle 50% of your data; the interquartile range (IQR = Q3 − Q1) measures how spread out that middle portion is.
Common mistakes
- Comparing this result directly with a spreadsheet's PERCENTILE.INC or PERCENTILE.EXC function — those use linear interpolation and can produce different Q1/Q3 values for the same data. No single quartile convention is universally "correct".
Assumptions and limitations
- Needs at least 2 values.