Quartiles are the three values that split a sorted dataset into four roughly equal parts, and they are among the most useful descriptive statistics precisely because they are simple and robust. The median, the middle value, is the second quartile. The first quartile, Q1, is the value below which about a quarter of the data falls. The third quartile, Q3, is the value below which about three quarters fall. Together with the minimum and maximum, they form the five-number summary, the basis of the box plot, one of the most informative charts in statistics. Unlike the mean and standard deviation, quartiles are barely moved by extreme values, which makes them the right tool whenever a dataset contains outliers or is skewed.

The method begins with sorting, which is non-negotiable: quartiles are defined on ordered data, and any calculation on unsorted data is meaningless. Once sorted, the median is found. For an odd count, it is the middle value; for an even count, it is the average of the two middle values. Q1 is then the median of the lower half of the data, and Q3 is the median of the upper half. One detail causes endless confusion: when the count is odd, the overall median itself is sometimes included in both halves and sometimes excluded from both, and different software packages choose differently. For the even-count case, which is the most common in textbook examples, there is no ambiguity, because the data splits cleanly into two equal halves. For odd counts, state the convention used or use a calculator whose method is documented, and do not be surprised if two tools differ slightly on small datasets. The difference is a matter of convention, not of one tool being wrong.

Consider a worked example with twelve values, so the halves split cleanly. A shop records the following daily sales counts over twelve days, already sorted: 3, 7, 8, 12, 13, 14, 18, 21, 22, 24, 29, 35. The median is the average of the sixth and seventh values, 14 and 18, which is (14 + 18) / 2, which is 16. The lower half is the first six values, 3, 7, 8, 12, 13, 14, and its median is the average of its two middle values, 8 and 12, which is (8 + 12) / 2, which is 10. So Q1 is 10. The upper half is the last six values, 18, 21, 22, 24, 29, 35, and its median is the average of its two middle values, 22 and 24, which is (22 + 24) / 2, which is 23. So Q3 is 23. The five-number summary is therefore: minimum 3, Q1 10, median 16, Q3 23, maximum 35. Each quartile can be read directly: a quarter of the days sold 10 or fewer, half sold 16 or fewer, and three quarters sold 23 or fewer.

The interquartile range, or IQR, is Q3 minus Q1, and it measures the spread of the middle half of the data. In the example, the IQR is 23 − 10, which is 13. The IQR is valuable because it describes typical variation while ignoring the extremes: a dataset with a few wild values can have an enormous range but a modest IQR, and the IQR tells you what variation looks like for the bulk of the observations. It is also the basis of the standard outlier rule: values below Q1 − 1.5 × IQR or above Q3 + 1.5 × IQR are flagged for investigation. In the example, the lower fence is 10 − 1.5 × 13, which is 10 − 19.5, which is −9.5, and the upper fence is 23 + 1.5 × 13, which is 23 + 19.5, which is 42.5. Every value in the dataset lies between −9.5 and 42.5, so no value is flagged as an outlier, which matches the visual impression of a reasonably spread but unremarkable dataset.

Quartiles also have a direct interpretation in percentiles. Q1 is the 25th percentile, the median is the 50th percentile, and Q3 is the 75th percentile. That language is useful when communicating with non-statisticians: saying "the 75th percentile of delivery times is 23 minutes" is immediately understandable, while "Q3 is 23" requires explanation. Percentiles generalise quartiles to any split, tenths for deciles and hundredths for percentiles, but quartiles remain the most commonly used because four groups are easy to reason about and to draw. A box plot draws exactly this information: a box from Q1 to Q3 with a line at the median, whiskers extending to the most extreme values within the fences, and individual points for flagged outliers. One box plot can convey centre, spread, skew, and outliers at a glance, which is why it is a standard first chart for any new dataset.

Skew shows up clearly in quartile positions. In a symmetric dataset, the median sits halfway between Q1 and Q3, and the two halves of the box are equal. In the example, the median of 16 sits between Q1 of 10 and Q3 of 23: the distance from Q1 to the median is 6, and from the median to Q3 is 7, so the distribution is close to symmetric with a slight rightward stretch, consistent with the maximum of 35 pulling the upper tail. In a strongly right-skewed dataset, such as incomes or house prices, the median sits much closer to Q1 than to Q3, and the upper whisker stretches far. That visual signature is often the first clue that the mean will be misleading: in right-skewed data the mean is pulled above the median by the upper tail, sometimes dramatically, while the quartiles stay representative of the typical experience.

Comparing groups is where quartiles earn their keep. Two classes with the same average test score can have very different quartile profiles: one tightly clustered, the other split between high and low achievers, and the teaching response should differ. Two delivery services with the same median time can differ in Q3, meaning one is far less reliable at the slow end. When comparing, place the five-number summaries or box plots side by side and look at all five numbers, not just the medians. A difference in Q1 alone, for example, means the groups differ mainly among their lowest values, which suggests a different story from a difference in Q3 alone.

There are limits to respect. Quartiles summarise position, not shape in detail: two datasets can share the same quartiles while differing in ways that matter, such as bimodality, where values cluster at two separate peaks. Quartiles do not describe relationships between variables, and they do not, on their own, support claims about causes. And with very small datasets, quartiles are unstable: adding or removing one value can shift Q1 or Q3 substantially, so quartile summaries of fewer than about ten observations should be presented with the raw data alongside. As with all summary statistics, the honest practice is to report the quartiles together with the sample size and, where feasible, the data itself.

Try it next: use the Quartile Calculator on your own dataset, then screen for unusual values with the Outlier Calculator and summarise centre and spread with the Standard Deviation Calculator. For background reading, see Profit, Margin and Break-Even Explained.