Bar chart

On this page 7

A bar chart is a chart that represents values of discrete categories as rectangular bars whose length is proportional to the value each bar stands for. In data visualization, it is the default choice for comparing quantities across categories, such as sales by region, survey answers by option or defects by cause.

The bar chart works because it encodes data as length from a common baseline, one of the most accurately perceived visual encodings. That strength comes with a firm rule: because the eye compares whole bar lengths, the value axis of a bar chart must start at zero.

How a bar chart encodes data

A bar chart has a categorical axis, which lists the items being compared, and a quantitative axis, which carries the numeric scale. Each bar begins at the baseline and ends at its value, so both the position of the bar end and the bar length convey the same number.

Perception research on graphical encodings, most notably the experiments of Cleveland and McGill, found that people judge position along a common scale and length far more accurately than angle, area or color intensity. The table below summarizes this ranking and why it favors bar charts.

EncodingTypical chartRelative accuracy
Position on a common scaleBar chart, dot plotHighest
LengthBar chart, stacked segment on a shared baselineHigh
Angle and slopePie chart, line slopeModerate
AreaBubble chart, treemapLow
Color saturationHeatmap, choropleth mapLowest for exact values
Accuracy of common visual encodings for comparing quantities

Bars can run vertically, often called a column chart, or horizontally. Horizontal bars are preferable when category labels are long or when there are more than about ten categories, because labels remain readable without rotation.

Types of bar chart and when each fits

Variants of the bar chart extend it to subgroups, part-to-whole questions and values above and below a reference. Each variant answers one question well and makes others harder, so the choice should follow the main comparison the reader needs to make.

VariantBest forMain limitation
Simple bar chartComparing one measure across categoriesShows only one series
Grouped bar chartComparing a few subgroups within each categoryBecomes cluttered beyond 3-4 subgroups
Stacked bar chartTotals plus their compositionInner segments lack a common baseline
100% stacked bar chartComparing shares across categoriesHides absolute totals
Diverging bar chartPositive and negative values or Likert scalesNeeds a clearly marked center line
Lollipop or dot plotMany categories with similar valuesWeaker sense of magnitude than a filled bar
Bar chart variants and their best use

The weakness of the stacked bar chart deserves emphasis. Only the bottom segment and the total sit on a common baseline; middle segments float, so comparing them across bars forces the reader to judge lengths at different starting points, which is much less accurate.

Bar charts are often confused with histograms and are often replaced, sometimes wrongly, by line charts or pie charts. The key question is whether the horizontal axis holds separate categories, continuous bins or ordered time.

ChartAxis typeAnswers the questionBars touch
Bar chartDiscrete categoriesHow do categories compareNo, gaps separate bars
HistogramContinuous bins of one variableHow are values distributedYes, bins are adjacent
Line chartOrdered, usually continuous timeHow does a value change over timeNot applicable
Pie chartParts of one wholeWhat share does each part takeNot applicable
HeatmapTwo categorical or binned dimensionsWhere are the high and low valuesNot applicable
When to use a bar chart instead of a related chart

Time can appear on a bar chart when periods are few and discrete, such as quarterly revenue for two years. For long or dense series, a line chart shows the trend more clearly, because it emphasizes change between points rather than the size of each point.

Design rules for clear bar charts

A clear bar chart follows a small number of design rules that keep the encoding honest and the comparison fast. These rules apply equally to static reports and to dashboard widgets.

  • Start the value axis at zero. Bar length must be proportional to value; a truncated axis exaggerates differences.
  • Sort bars by value when categories have no natural order, so the ranking is visible at a glance.
  • Keep a natural order when it exists, such as age bands, months or satisfaction levels.
  • Set gaps at roughly half a bar width or somewhat less, so bars read as separate items without wasting space.
  • Use one color for one series and reserve an accent color for the bar that carries the message.
  • Label values directly on or next to the bars when exact numbers matter, and remove gridlines that the labels make redundant.

Common bar chart mistakes

Most misleading bar charts result from breaking the length encoding, often unintentionally. A truncated axis is the classic case: if one value is 96 and another is 100 and the axis starts at 90, the second bar is about 67% longer, although the real difference is only about 4.2%.

MistakeEffect on the readerFix
Truncated value axisSmall differences look largeStart at zero, or switch to a dot plot
3D bars or perspectiveBar ends are hard to read against the axisUse flat 2D bars
Too many categoriesLabels overlap and ranking is lostShow the top items and group the rest as other
Logarithmic value axisBar length no longer reflects magnitudeUse points on a log scale instead of bars
Bars for averages onlySpread and sample size are hiddenAdd error bars or show individual points
Rainbow colors without meaningReader searches for a nonexistent patternUse a single color plus one highlight
Frequent mistakes, their effect and the fix

Explained without jargon

A bar chart turns numbers into bars so that bigger numbers get longer bars. Instead of reading a table of figures, the eye simply looks for the longest and shortest bars and sees the ranking at once.

It works like comparing people standing side by side on the same floor. Their heights are easy to compare because everyone starts from the same level. If some people stood on boxes, the comparison would mislead, and that is exactly what happens when a bar chart does not start at zero.

A typical use case

A customer support manager wants to know why ticket volume rose during the last quarter. The team logged 5,000 tickets across 12 categories, and the raw table makes it hard to see which issues dominate.

An analyst builds a horizontal bar chart sorted from largest to smallest, with the value axis starting at zero and each count labeled at the end of its bar. Billing questions lead with 1,240 tickets, login problems follow with 980, and delivery delays come third with 680. Together, the top three categories account for 58% of all tickets, while the remaining nine share the rest.

The billing bar is highlighted in an accent color while all other bars stay gray. In a single slide, the manager sees where effort will have the greatest effect and funds a redesign of the invoice page as the first improvement project.