Bar chart vs histogram: what is the difference?
Both charts are made of bars, so they are often swapped, but they answer different questions. A bar chart compares the value of each category. A histogram shows how numbers are distributed: where they cluster and whether there are extreme values.
Bar Chart
Sales by branch. Each bar is one branch.
Histogram
Number of people by value range. Each bar is one range.
Point by point
| Aspect | Bar Chart | Histogram |
|---|---|---|
| What a bar stands for | A category, such as a branch, department or product | A range of numbers, such as a salary of 20,000–30,000 |
| Height of the bar | The value for that category, such as sales or an average | The number of data points that fall in that range |
| Gaps between bars | Yes, because each bar is a different category | No, because the ranges are continuous |
| Can the bars be reordered? | Yes. Sort from largest to smallest to make comparison easy | No. They must follow the numeric order |
| Data you need | A category name and a value for each category | Raw numbers, one per item, such as each customer's age |
| Answers the question | Which category is bigger? | Where do most values lie, and how are they spread? |
| What the reader can adjust | Nothing to decide | The bin width; change it and the shape changes |
Which one fits the data you have
- Bar Chart · You have sales for 10 branches and want to know which sells the most
- Histogram · You have the ages of 5,000 customers and want to know what age most are
- Bar Chart · You have the average salary for each department
- Histogram · You have every employee's salary and want to know where they cluster and whether anyone is unusually high
Common mistakes
1. Using a histogram to compare categories
Bars that touch make readers think the categories are continuous and cannot be reordered. For categories, use a bar chart.
2. Making your own bins in a bar chart with unequal widths
With 0–10, 10–20, 20–50, the bar for the wider range looks too tall. Use equal-width bins, or use a histogram that calculates the bins for you.
3. Trying only one number of bins in a histogram
Too few bins and the shape vanishes; too many and it turns spiky. Try several and pick the one that shows a clear shape without spikes.
Frequently asked questions
Why does a histogram have no gaps between bars?
Because the horizontal axis is a continuous number: one range ends where the next begins. A gap would look like missing values.
If I already have age bands, such as 18–25 and 26–35, which should I use?
If the bands are equal in width and you want to compare headcounts, a bar chart works. If you have each person's age, use a histogram to see the real distribution.
Can a bar chart be sorted by value, and can a histogram?
A bar chart can and should be sorted. A histogram must follow the numeric order, or the shape of the distribution is lost.