Grouped bar chart

Grouped bar chart is a type of bar graph that is used to compare values across multiple categories.

Usage guidelines

Like a bar chart, the grouped bar chart is built for showing a distribution of data points or to make comparisons across different categories of data. But it is different because Group bar charts add an extra dimension for comparison.

Use grouped bar charts when you want to compare data using 2 categorical dimensions. For example compare retirement age of men and women across different countries. Where gender is one categorical dimension and country is another one. This way you can focus on:

  • comparing retirement age of women and men between each other for a particular country, or
  • comparing retirement age of a specific gender across different countries.

There is no conceptual limit to the number of categorical items you can include in a single graph, but practically speaking — using too many categories will put more mental strain on the viewer. We advise to not use more than 4 categories.

Don't use grouped bar charts if you want to compare totals across different categories — think of using stacked bar chart instead.

Bar width and spacing

Bar width and spacing

The width and the spacing between bars do not convey any data. Make total bar width twice as thick as the space between them — this will leave enough space inbetween the groups to ease the scanning.

1x — space between bars

2x — a total width of all bars, twice as wide as space between bars.

Baseline

It is important to start all bar charts with 0, otherwise relative comparison becomes really difficult. This is because our eye compares the bar’s length in relation to each other. By starting at the value of zero you maintain the truthfulness of your message.

Baseline do

Always start at the value of 0. This way you convey a truthful message.

Baseline don't

The example above gives does not start at 0 and thus giving a false impression of Portugal having x6 more stray dogs than the UK.

When the baseline on a bar chart interferes with the perception of differences between bars, then a line chart or dot plot is a good alternative.

Colors

Color is a tool that helps distinguish categories in the grouped bar chart. It is important to be mindful of the palette used to display different data types.

Colors categorical

Categorical palette

Use this palette to display distinct categories.

Colors sequential/divergent

Sequential / Divergent palette

Use either of these palettes when values follow a natural order.

See more details on which colors we use for different data sets.

Behavior

Here are some examples of behaviors that are unique to Grouped bar charts. For other behaviors like loading, error and empty states, check behavior guidelines.

Behavior hover

Hover

Hovering over a bar or the corresponding axis label causes all the other bars to fade back from the view. A tooltip displays the dimension value and the corresponding metric value.

Learn more on the anatomy of a tooltip.

Behavior missing data point

Missing data points

When there is no data available display it as zero and add ‘no data’ in the chart tooltip.

Chart variations

Not what you’re looking for? Here are some grouped bar chart variations.

  • Bar chart: use it to display quantitative values for different categories. The main purpose of a bar chart is to compare individual data points with each other.
  • Stacked bar chart: use it to display a part-to-whole breakdown of quantitative values for different categories. The whole could represent 100% or an absolute value.
  • Multi-line chart: use it to detect trends and patterns, not to display exact quantitative readings

bar chart

stacked bar chart

line chart