Excel Box Plot: Show the Median Line, Not the X

How-to basics · Updated November 3, 2026

Excel Box Plot: Show the Median Line, Not the X

In an Excel box plot, the horizontal line inside the box is the median; an X is the mean, not a median symbol. To remove the X in Excel for Microsoft 365 on Windows, right-click the box-and-whisker series, choose Format Data Series, open Series Options, and clear Show mean markers. The median line remains visible.

What the X means in an Excel box plot

A box-and-whisker chart summarizes the distribution of a set of numbers. Its box represents the middle half of the data, while whiskers extend toward values at the ends of the distribution. Excel draws the median as a horizontal line across the box. When mean markers are enabled, Excel displays an X to show the arithmetic mean—the sum of the observations divided by their count.

The mean and median are different measures of center, so their symbols can appear in different places. For example, if a group of values is 2, 3, 4, 5, and 16, the median is 4, while the mean is 6. The high value pulls the mean upward. In a box plot, the median line would sit at 4 and the mean X at 6. If the two markers are close together, it can be easy to mistake the X for a median marker.

Excel may also show a line connecting mean markers across categories if the mean-line option is enabled. That line represents means, not medians. It does not replace the median line inside each box.

Hide the mean X in Excel for Windows

To remove the X without changing the underlying data or the median, change the series display options:

  1. Click the box-and-whisker chart, then click one of its boxes to select the data series.
  2. Right-click the selected series and choose Format Data Series. The formatting pane opens on the right.
  3. In the pane, select Series Options, represented by the chart-series icon if the pane shows icons.
  4. Under Box & Whisker Options, clear Show mean markers.

The X markers should disappear, while the median lines remain. If the pane is not showing the box-and-whisker options, check that the chart is a Box & Whisker chart and that the series, rather than the chart area or an axis, is selected. You can also select the chart, open the Format tab, and use the Current Selection controls to choose a series before opening Format Selection.

To show the X again, return to the same setting and select Show mean markers. This setting changes what the chart displays; it does not delete or edit any values in the worksheet.

Why you cannot turn the median X into a line

Excel does not normally draw the median as an X in a box-and-whisker chart. The X is the mean marker, and the median is already the line across the box. There is therefore no setting that converts that X into the median line: the two marks refer to different statistics. If the goal is simply to make the median easier to see, keep the built-in median line and hide the mean marker.

If you want to show a line for the mean instead, select the series and, in Series Options, turn on Show mean line. This connects the mean values for the categories in the chart. It is useful when comparing how averages change between groups, but it can be confusing if readers interpret it as a median line. A mean line may also cross the boxes or whiskers, so label it clearly and consider whether the connection between categories makes sense for your data.

Make the median line easier to read

The median is part of the box plot itself, not an optional mean-marker setting. Excel’s built-in formatting options are primarily for the appearance of the series as a whole; they may not offer a separate control for changing only the median line’s color, width, or dash style. If the default median line is hard to distinguish, try improving the chart’s overall contrast first:

  • Choose a box fill that contrasts with the median line.
  • Use a chart style with clear outlines and a simple background.
  • Increase the chart size or reduce visual clutter from gridlines and labels.
  • Keep mean markers off if the X distracts from the median.

To change a series’ appearance, select the box, right-click, and choose Format Data Series. The pane includes formatting controls for the series, but changes there can affect the boxes or other series elements rather than just the median. Check the result at normal viewing size, and avoid relying on a color distinction that is difficult to see when printed or viewed by someone with color-vision differences.

If you specifically need a prominent median line with a custom style, you can add a line shape over the chart as a visual annotation. This is a manual overlay, not a data-linked median, so it can become misplaced when the chart is resized, axes change, or data updates. For a chart that must update reliably, consider creating a custom visualization from the calculated summary statistics instead.

Confirm the chart type and data arrangement

The steps above apply to Excel’s built-in Box & Whisker chart, available in Microsoft 365 for Windows. If your graphic has an X but no box, or if the right-click menu does not offer Format Data Series options for a box plot, it may be a different chart type or a manually assembled diagram. Select the chart and check the chart type from Chart Design > Change Chart Type. A built-in box plot appears under Statistical as Box & Whisker.

Excel interprets the worksheet layout when it builds the chart. Usually, each group is a separate data series, with the observations arranged in a column or row. If the chart groups the data in the wrong direction, use Chart Design > Switch Row/Column or adjust the source-data layout. This changes which observations belong to each box; it does not change what the X or median line means.

It is also useful to check the chart legend and axis labels. If multiple groups have similar values, a mean X can fall inside a box or close to its median line. A clear group name and an explanation of the symbols help readers distinguish the statistics.

Quartiles, whiskers, and chart interpretation

Removing the mean X does not change the box, whiskers, quartiles, or outlier points. The box shows the lower and upper quartiles, with the median line between them. Whiskers and any displayed points provide additional information about the distribution. The exact appearance depends on the chart’s options and the data, so do not assume that every mark is a median.

Excel’s Box & Whisker Options include a choice between inclusive and exclusive median calculations for quartiles. The choice affects how Excel calculates the quartile boundaries, particularly in smaller samples; it can change the box even though the median is still represented by the line. When comparing box plots, use a consistent quartile method across groups and document the choice if the result will be used in a report.

For example, suppose you compare delivery times for three services. The median line shows the middle delivery time in each group, while an X, if enabled, shows the arithmetic average. A few unusually long deliveries can pull the average above the median. Showing both may be informative, but the X should not be described as a second median or used as a substitute for it.

Common problems and fixes

  • The X remains after clearing mean markers: Confirm that the correct series is selected and check whether the chart contains more than one series. Each series can have its own display settings.
  • The median line seems missing: Look inside the colored box, where the median line is drawn. If it blends into the fill or border, change the series styling or enlarge the chart. A very small box can make the line difficult to distinguish.
  • A line appears to connect the X symbols: Check Show mean line in Series Options. That line connects means; it is separate from the median lines inside the boxes.
  • The X appears outside the box: That can happen when the mean differs from the median, especially with skewed data or extreme values. It is not necessarily a chart error.
  • The options are not available: Verify that the selected chart is Excel’s Box & Whisker type and that you selected the data series. Other chart types have different formatting controls.

Excel for Mac and Excel for the web

On Excel for Mac, select or Control-click the box-and-whisker series and open Format Data Series. Look for the same Box & Whisker Options and clear Show mean markers. The pane layout can differ slightly from the Windows interface, but the distinction between the mean X and median line is the same.

Excel for the web may offer fewer chart-editing controls than the desktop app, and the available options can vary. If you cannot find the mean-marker setting in the browser, open the workbook in the Excel desktop app and make the change there. The chart’s displayed marks do not alter the worksheet values.

Frequently Asked Questions

Is the X in an Excel box plot the median?
No. The X marks the mean when Show mean markers is enabled. The median is the horizontal line inside the box.

How do I remove the X but keep the box plot?
Right-click the series, choose Format Data Series, open Series Options, and clear Show mean markers. The box plot and its median line remain.

Can I show the median as an X instead?
Excel’s built-in box-and-whisker chart uses a line for the median and an X for the mean. There is no standard option to swap those symbols. A manually added marker would be an overlay, not a chart-linked median symbol.

Does Show mean line draw the median?
No. It connects mean values across categories. The median remains the line within each box.

Will hiding the X change my data or calculations?
No. It only hides the mean marker in the chart. Your worksheet values and the chart’s median, quartiles, and other statistics are not changed by that display setting.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.