What a legend does and where to put it

A legend in Excel is a box that identifies what each color, pattern, or line in your chart represents. When you create a chart from data in Excel, the legend automatically appears — usually on the right side of the chart — but you can move it, resize it, or remove it entirely depending on what your chart needs.

The legend pulls its labels directly from your data. If your spreadsheet has a row or column of category names, Excel uses those names in the legend. If you change the name in your data, the legend updates automatically.

Most charts benefit from a legend when they show more than one data series — for example, a chart comparing sales across three regions, or showing both revenue and expenses over time. A single-series chart (like a pie chart showing one year's budget breakdown) usually doesn't need a legend because the chart itself labels each slice.

Key Takeaways

  • Excel adds a legend automatically when you create a chart, positioned on the right by default, and you can move it by clicking and dragging.
  • To change where the legend appears, right-click it, select "Format Legend", and choose a new position from the options provided.
  • You can delete a legend by clicking it once and pressing Delete, or by right-clicking and selecting "Delete".
  • The legend text comes from your spreadsheet data, so updating a category name in your data updates the legend without extra steps.
  • Some chart types like pie charts rarely need legends because the chart itself labels each segment.

Moving a legend to a different location

When Excel creates your chart, it places the legend on the right side by default. If that overlaps your data or doesn't match your layout, you can move it in seconds.

Click once on the legend box itself — you'll see a border appear around it with small squares at the corners and edges. Now click and drag the legend to wherever you want it. You can place it on the left, top, bottom, or even inside the chart area if there's empty space.

If you want more control over the exact position, right-click the legend and select Format Legend. A panel opens on the right side of your screen. Look for the Legend Position section and choose from preset locations: Right, Left, Top, Bottom, or Top Right Corner. Pick whichever keeps your data visible and your chart readable.

Removing a legend you don't need

Not every chart needs a legend. A pie chart showing one year's expenses by category, for example, is usually clearer without one — the slice labels do the job.

To delete the legend, click it once to select it, then press the Delete key. The legend disappears immediately. If you change your mind, press Ctrl+Z (or Cmd+Z on Mac) to undo and bring it back.

You can also right-click the legend and select Delete from the menu that appears. Both methods work the same way.

Editing what the legend says

The legend text comes from your spreadsheet. If your data has a row or column header that says "Region A", "Region B", and "Region C", those exact names appear in the legend.

To change what the legend displays, edit the names in your original data. For example, if your spreadsheet column header says "Q1 Sales" and you change it to "First Quarter Sales", the legend updates automatically the next time you look at the chart.

If you want to rename just the legend entry without changing your data, right-click the legend, select Format Legend, and look for text editing options. However, the simpler approach is usually to update the source data itself, because that keeps your spreadsheet and chart in sync.

Resizing the legend box

If your legend text is cramped or the box is too large, you can resize it. Click the legend once to select it — you'll see small squares appear at the corners and edges of the box. Drag any of these squares to make the legend wider, taller, or smaller.

Dragging a corner square resizes both width and height at once. Dragging a side or top/bottom square resizes in just one direction. If the text wraps awkwardly after resizing, try making the box wider.

Changing legend appearance and text size

Right-click the legend and select Format Legend to open the formatting panel. From here you can change the background color, add a border, or adjust the text size.

Look for the Text Options section in the panel. You can increase or decrease the font size, change the font family, or make the text bold or italic. These changes apply to all the legend text at once — you can't format individual entries differently without more advanced steps.

If you want the legend to stand out less, try a light background color or remove the border entirely. If you want it to stand out more, add a dark border or a contrasting background.

When your legend shows the wrong data

Sometimes a legend includes entries you didn't expect, or leaves out ones you need. This usually happens because Excel misread which part of your data contains the series names.

Right-click the chart (not the legend) and select Select Data. A dialog box opens showing all the data series Excel found. You'll see a list on the left labeled "Legend Entries (Series)". If an entry shouldn't be there, click it and select Remove. If you're missing an entry, click Add and point Excel to the correct data range.

This usually happens when your data layout is unusual — for example, if you have extra rows or columns that Excel thought were part of the chart data. Cleaning up the data range fixes the legend.

Frequently Asked Questions

Can I have the legend show only some of my data series?

Yes. Right-click the chart and select Select Data. In the dialog that opens, you'll see all your data series listed on the left. Click any series you don't want in the legend and select Remove. The legend updates to show only the remaining series, though the removed data still appears in the chart itself.

Why does my legend say "Series 1" and "Series 2" instead of real names?

Excel couldn't find category names in your data, so it used generic labels instead. Go back to your spreadsheet and add a header row or column with the names you want — for example, "North Region" and "South Region". Then recreate the chart or right-click the chart and select Select Data to point Excel to those names.

Can I move the legend inside the chart area?

Yes. Right-click the legend, select Format Legend, and choose Top Right Corner or another position that places it inside the chart. You can then drag it to fine-tune the exact spot. Make sure it doesn't cover important data.

What if I delete the legend by mistake?

Press Ctrl+Z (or Cmd+Z on Mac) immediately to undo. If you've made other changes since, right-click the chart and look for a Legend option in the menu, or use the Chart Design tab at the top to add it back.

Does the legend update automatically if I change my data?

Yes. If you edit a category name in your spreadsheet, the legend reflects that change the next time you view the chart. You don't need to recreate the chart or manually update the legend.