Labels and legends

How to label a chart so people can tell what it shows, from series and categories to data values.

Category labels name the groups along an axis, such as ports, months or trade lanes. This page covers how to show them. For how to name and order categories, see Data categories.

Keep category labels horizontal

Horizontal text is the easiest to read. When labels are long, switch from vertical to horizontal bars instead of rotating the text, because horizontal bars give labels more room. If the chart can’t be switched to horizontal bars, such as a line chart, use the steps below.

Do
Use horizontal bars when category labels are long.
Caution
Rotated labels are harder to read, so avoid them where you can.

When labels still don’t fit

If labels still don’t fit, try these in order:

  1. Wrap them: break long labels onto more than one line.
  2. Shorten them deliberately: don’t cut labels off with an ellipsis, because similar names then look the same, such as “Port of Tanjung Pe…” and “Port of Tanjung Pr…”. If you shorten a name, make the full name available, for example in a tooltip or a note below the chart.
  3. Show fewer labels: on an ordered axis, such as time, leave out some labels, for example every other month.
Wrap long labels onto more than one line.
Shorten names deliberately.
Show every other label on a crowded time axis.

See also