
When working with data, knowing how it’s distributed can be just as important as knowing the average. A box and whisker plot, sometimes called a box plot, is a simple yet powerful chart that gives you a clear snapshot of your data’s spread, center, and outliers all in one visual.
A box and whisker plot is a type of chart that summarizes a dataset using five key values: the minimum, the lower quartile (Q1), the median (Q2), the upper quartile (Q3), and the maximum. Together, these five points give you a quick, honest picture of how your data behaves — where it clusters, how widely it spreads, and whether any values sit far outside the norm.
The “box” in the chart represents the middle 50% of your data, stretching from Q1 to Q3. This range is known as the interquartile range, or IQR. A line inside the box marks the median. The “whiskers” extend outward from either side of the box toward the minimum and maximum values, showing the full reach of your data.
Box plots are especially useful when comparing two or more datasets side by side. Rather than sifting through raw numbers, a quick glance at the boxes and whiskers tells you which dataset is more spread out, which has a higher median, and where the bulk of each dataset falls. That makes them a favorite in fields like education, medicine, finance, and scientific research.
Before you can draw a box and whisker plot, you need to calculate the five numbers that define it. These five values – collectively called the five-number summary – describe the shape and spread of your dataset in a way that a single average simply cannot.
1. The Minimum The minimum is the smallest value in your dataset, excluding any outliers. It marks the far left end of the lower whisker on your plot.
2. The Lower Quartile (Q1) Q1 is the median of the lower half of your data — the point at which 25% of your values fall below. It forms the left edge of the box.
3. The Median (Q2) The median is the middle value of your entire dataset when arranged in order. If you have an even number of values, it’s the average of the two middle numbers. The median appears as a vertical line inside the box, and it tells you where the center of your data lies.
4. The Upper Quartile (Q3) Q3 is the median of the upper half of your data — the point at which 75% of your values fall below. It forms the right edge of the box.
5. The Maximum The maximum is the largest value in your dataset, excluding outliers. It marks the far right end of the upper whisker.
Once you have all five numbers, you also have the interquartile range (IQR), calculated as Q3 minus Q1. The IQR tells you how spread out the middle 50% of your data is, and it plays an important role in identifying outliers — which we’ll cover shortly.
Use a box and whisker plot when:
You want to show the spread of a dataset. If your goal is to communicate how widely your data is distributed, a box plot does this at a glance. The length of the box and the reach of the whiskers immediately signal whether your data is tightly packed or widely scattered.
You’re comparing two or more groups. Box plots shine when placed side by side. Comparing student test scores across three classrooms, patient recovery times across two treatments, or monthly sales across four regions becomes straightforward when each group gets its own box plot on the same axis.
Your dataset is large. A simple list of numbers or even a basic bar chart can become overwhelming when you’re working with hundreds or thousands of data points. A box plot condenses all of that into five values without losing the story the data is telling.
You want to spot outliers. Because box plots flag values that fall unusually far from the rest of the data, they’re a practical first step in any data cleaning or analysis process.
Consider a different chart when:
Your dataset is very small. With fewer than six or seven data points, a box plot can actually obscure more than it reveals. A simple dot plot or table may serve you better.
Your audience needs to see individual values. Box plots summarize data — they don’t display every point. If the specific values matter to your audience, a scatter plot or line chart may be a stronger choice.
You need to show a trend over time. Box plots are built for distribution, not change over time. For trends, a line chart is the more natural fit.
Example dataset: 4, 7, 8, 12, 13, 15, 18, 21, 24
Step 1: Arrange Your Data in Order Make sure all your values are sorted from smallest to largest. Our example dataset is already ordered, but this step is easy to overlook with messier data.
Step 2: Find the Five-Number Summary Work through each of the five key values:
Your five-number summary is: 4, 7.5, 13, 19.5, 24
Step 3: Draw a Number Line Draw a horizontal number line that comfortably spans your full data range. In this case, make sure it runs from below 4 to above 24. Add evenly spaced tick marks and label them clearly.
Step 4: Mark the Five Values Above the number line, place a small vertical tick mark at each of your five values: 4, 7.5, 13, 19.5, and 24.
Step 5: Draw the Box Draw a rectangle connecting Q1 (7.5) and Q3 (19.5). The box should sit cleanly above the number line. Then draw a vertical line inside the box at the median value (13).
Step 6: Draw the Whiskers Extend a horizontal line — the whisker — from the left edge of the box out to the minimum value (4). Draw a second whisker from the right edge of the box out to the maximum value (24). Cap each whisker with a small vertical line to mark the endpoint clearly.
Step 7: Check for Outliers To check whether any values should be treated as outliers rather than included in the whiskers, calculate the IQR and apply the standard rule:
Any value below −10.5 or above 37.5 would be plotted as an individual dot beyond the whisker rather than included in it. In our dataset, no outliers exist, so the whiskers extend to the true minimum and maximum.
Your finished plot gives an immediate visual summary: the bulk of the data sits between 7.5 and 19.5, the center falls at 13, and the data stretches from 4 to 24 with no unusual values pulling it in either direction.
If you’re working with a larger dataset or simply want a cleaner, more polished result, Excel can build a box and whisker plot for you in just a few clicks. Excel 2016 and later versions include a built-in box plot chart type, which makes the process straightforward.
Step 1: Enter Your Data Open a new spreadsheet and enter your dataset in a single column. Label the top of the column so you can identify it easily. If you’re comparing multiple groups, place each group in its own column with a label at the top.
For example:
| Group A | Group B |
|---|---|
| 4 | 11 |
| 7 | 14 |
| 8 | 15 |
| 12 | 17 |
| 13 | 19 |
| 15 | 22 |
| 18 | 24 |
| 21 | 28 |
| 24 | 30 |
Step 2: Select Your Data Click and drag to highlight all the data you want to include in your chart, including the column headers.
Step 3: Insert the Chart With your data selected, go to the Insert tab in the ribbon at the top of the screen. In the Charts group, click the “Insert Statistic Chart” button — it looks like a small histogram icon. From the dropdown menu that appears, select Box and Whisker under the Statistical section.
Excel will instantly generate a box and whisker plot from your selected data.
Step 4: Customize Your Chart Excel’s default chart is functional, but a few quick adjustments will make it clearer and more presentation-ready.
Step 5: Understand What Excel Is Showing You By default, Excel calculates and displays the five-number summary automatically. It also marks outliers as individual dots beyond the whiskers, which is standard practice. One thing worth noting: Excel uses the exclusive quartile method to calculate Q1 and Q3, which can produce slightly different results from manual calculations depending on your dataset size. For most purposes, this difference is minor and won’t affect your interpretation.
A Note for Older Versions of Excel If you’re using Excel 2013 or earlier, there is no built-in box plot option. You can still create one by building a stacked bar chart and manually adjusting it to resemble a box plot — but the process is lengthy. In that case, it may be easier to use a free alternative such as Google Sheets, which also supports box plots natively.

Excel isn’t the only option for building box and whisker plots. Depending on your workflow, skill level, or the tools you already use, one of these alternatives may suit you better.
Google Sheets supports box plots natively and is a solid choice if you work in a browser or collaborate with others in real time. Enter your data in columns, select it, then click Insert → Chart. In the Chart Editor panel on the right, open the Chart type dropdown and select Candlestick chart — Google Sheets does not label it as a box plot, but with the right data arrangement it produces the same result. For a true box plot with automatic quartile calculations, consider using Google Sheets alongside a free add-on such as XLMiner Analysis ToolPak.
R is a favorite among statisticians and data scientists, and creating a box plot with the ggplot2 package takes just a few lines of code. Once your data is loaded into a data frame, the following produces a clean, publication-ready box plot:
r
library(ggplot2)
ggplot(your_data, aes(x = group, y = value)) +
geom_boxplot() +
labs(title = "Box and Whisker Plot", x = "Group", y = "Value")
ggplot2 gives you fine-grained control over colors, themes, labels, and outlier styling, making it one of the most flexible options available.
Python offers two popular libraries for box plots. Matplotlib provides a straightforward approach:
python
import matplotlib.pyplot as plt
data = [4, 7, 8, 12, 13, 15, 18, 21, 24]
plt.boxplot(data)
plt.title("Box and Whisker Plot")
plt.show()
Seaborn produces more visually polished results with less code and integrates cleanly with pandas data frames:
python
import seaborn as sns
import pandas as pd
sns.boxplot(x="group", y="value", data=your_dataframe)
Both libraries are free, widely documented, and capable of handling large datasets with ease.
Tableau is a powerful data visualization platform used widely in business and analytics. To create a box plot, connect your data source, then drag a dimension to the Columns shelf and a measure to the Rows shelf. From the Show Me panel on the right, select the box-and-whisker plot option. Tableau will calculate the five-number summary and render the chart automatically. Tableau Public, the free version, is a good starting point if you haven’t used the platform before.
Plotly’s Chart Studio is a browser-based tool that requires no coding or software installation. Upload your data, choose Box Plot from the chart type menu, and assign your columns to the appropriate axes. The tool generates an interactive chart you can embed in a website or export as an image. It’s a practical option for anyone who wants a quick, professional result without writing code.
IBM SPSS is a statistical software package commonly used in academic research and social sciences. To create a box plot, go to Graphs → Chart Builder, drag the Box Plot icon onto the canvas, and assign your variables. SPSS gives you precise control over how outliers and extreme values are identified and displayed, making it a strong choice for formal research contexts.
Each of these tools has its strengths. For quick everyday use, Google Sheets works well. For research and analysis, R or Python offer the most control. For business dashboards, Tableau is hard to beat. And for one-off charts without any setup, Plotly’s online editor gets the job done fast.
The Standard Outlier Rule
The most widely used method for identifying outliers in a box plot is the 1.5 × IQR rule, introduced by statistician John Tukey. Here’s how it works:
Any data point that falls below the lower fence or above the upper fence is considered an outlier.
Example: Using the dataset from our earlier example, where Q1 = 7.5 and Q3 = 19.5:
Any value below −10.5 or above 37.5 would be flagged as an outlier.
How Outliers Are Displayed
When a dataset contains outliers, the box plot adjusts automatically. Rather than stretching the whisker all the way to the outlying value, the whisker stops at the last data point that still falls within the fences. The outlier itself is then plotted as an individual dot or asterisk beyond the whisker’s endpoint. This keeps the main body of the chart scaled to where most of the data actually lives, while still making the outlier visible.
Mild vs. Extreme Outliers
Some box plots distinguish between two categories of outliers:
Not all software makes this distinction by default, but statistical tools like R and SPSS can be configured to display both categories separately.
Start With the Median
The vertical line inside the box is your first point of reference. It tells you where the center of your data sits. If the median line falls closer to the left edge of the box, the lower half of your data is more tightly packed and the upper half is more spread out. If it sits closer to the right edge, the opposite is true. A median line in the dead center of the box suggests a fairly balanced distribution.
Read the Box
The width of the box represents the interquartile range — the spread of the middle 50% of your data. A wide box means the data is broadly spread around the center. A narrow box means most values cluster closely together. This is one of the quickest ways to compare the consistency of two datasets: the group with the narrower box is the more consistent one.
Read the Whiskers
The whiskers show you how far your data extends beyond the middle 50%. A long whisker on one side indicates that values stretch out considerably in that direction. If both whiskers are roughly equal in length, the data is fairly evenly distributed. If one whisker is noticeably longer than the other, the data is pulled in that direction.
Assess the Skew
The shape of a box plot tells you whether your data is symmetric or skewed:
Look at Outliers
Individual dots plotted beyond the whiskers are outliers. A single outlier may not change your overall interpretation much, but several outliers clustered in one direction — or one extreme outlier far removed from the rest — is worth noting. It may point to measurement error, a genuinely unusual case, or a factor in your data that deserves further investigation.
Comparing Multiple Box Plots
Box plots become especially powerful when you line up two or more side by side on the same axis. When comparing, ask yourself:
A Practical Example
Imagine two classes took the same exam. Class A has a median score of 72, a box stretching from 65 to 80, and short whiskers. Class B has a median of 74 but a box stretching from 55 to 88, with a long upper whisker and two outliers below 45. At first glance, Class B’s slightly higher median might seem better — but the box plot tells a richer story. Class B’s scores are far more spread out, several students struggled significantly, and the outliers suggest a small group may need additional support. Class A, by contrast, performed more consistently across the board.
To find Q1 and Q3:
First, arrange the data in ascending order
Find the median (Q2)
Q1 is the median of the lower half of the data
Q3 is the median of the upper half of the data
A box plot summarizes data using quartiles and highlights outliers, while a histogram shows the frequency distribution of data using bars. Histograms provide more detail about data shape, while box plots are better for quick comparisons.
Yes, box plots can be used for small datasets, but they are more informative when there are enough data points to show distribution clearly.