The Quick Answer
A histogram is a chart that shows how data is distributed across a range. It groups values into "bins" (intervals) and uses bar heights to show how many values fall into each bin. Unlike bar charts, histograms display continuous numerical data — the bars touch because the bins represent adjacent ranges with no gaps.
When to use a histogram: Whenever you want to see the shape of your data — whether it clusters around a center, skews to one side, or has multiple peaks.
What a Histogram Actually Shows
Every histogram answers one question: "Where do most of the values fall?"
Suppose you have 50 exam scores ranging from 60 to 100. A histogram divides that range into bins — say, 60–65, 65–70, 70–75, and so on — then counts how many scores land in each bin. The result is a visual picture of the distribution:
- Tall bars mean many values in that range
- Short bars mean few values
- The overall shape reveals patterns that raw numbers hide
This is fundamentally different from looking at a list of numbers or even summary statistics like the mean. A dataset with a mean of 78 could be tightly clustered around 78, or it could have two separate groups at 60 and 96. The histogram shows you which.
How to Read a Histogram: 5 Things to Check
1. Center
Where is the bulk of the data? Look for the tallest bars. If most bars cluster around 75–85, that's your center — regardless of what the calculated mean says.
2. Spread
How wide is the distribution? Data spread across many bins indicates high variability. Data concentrated in a few bins indicates consistency.
3. Shape
The overall shape is the most informative feature:
- Symmetric (bell curve): Values are evenly distributed around the center. Example: adult heights, standardized test scores.
- Right-skewed (positive skew): A long tail extends to the right. The mean is pulled higher than the median. Example: household income, home prices.
- Left-skewed (negative skew): A long tail extends to the left. The mean is pulled lower than the median. Example: age at retirement, failure time of reliable components.
- Bimodal (two peaks): Two distinct clusters suggest two subgroups in the data. Example: exam scores where half the class studied and half didn't.
- Uniform (flat): All ranges have roughly equal frequency. Example: rolling a fair die many times.
4. Outliers
Look for isolated bars far from the main group. A single bar at the extreme right or left may represent outliers — values that are unusually high or low. Outliers can heavily influence the mean while barely affecting the median.
5. Gaps
Empty bins between populated ones can indicate distinct subgroups or measurement issues. A gap between two clusters often means you're looking at two different populations combined.
Histogram vs Bar Chart
This is one of the most common points of confusion. They look similar but serve different purposes:
| Feature | Histogram | Bar Chart |
|---|---|---|
| Data type | Continuous numbers (weight, time, temperature) | Categories (countries, products, ratings) |
| Bars | Touch each other (bins are adjacent ranges) | Have gaps (categories are distinct) |
| X-axis | Numerical scale | Category labels |
| Bar order | Fixed by the number line | Can be reordered (e.g., tallest first) |
| Purpose | Show distribution shape | Compare quantities across groups |
Rule of thumb: If your x-axis values are numbers on a continuous scale, use a histogram. If they are labels or categories, use a bar chart.
How to Choose the Right Number of Bins
The bin count changes what you see. Too few bins and you lose detail. Too many bins and you see noise instead of patterns.
Common Rules of Thumb
| Method | Formula | 100 data points | 1,000 data points |
|---|---|---|---|
| Square root | √n | 10 bins | 32 bins |
| Sturges' formula | 1 + 3.322 × log₁₀(n) | 8 bins | 11 bins |
| Rice's rule | 2 × n^(1/3) | 9 bins | 20 bins |
No formula is perfect. The best approach is to start with one of these rules and then adjust:
- Start with the square root rule (√n)
- Increase bins if the shape looks suspiciously smooth — you may be hiding real features
- Decrease bins if the chart looks noisy and random — you may be amplifying sampling variation
What "Too Few" and "Too Many" Look Like
With 5 bins on 200 data points, a bimodal distribution might look like a single hump — the two peaks get merged together.
With 50 bins on the same data, every bin has only a few values, creating a jagged, noisy chart where the underlying pattern is hard to see.
With 15 bins, the two peaks are visible and the shape is clear. That's the sweet spot.
Worked Example: Exam Scores
Suppose a class of 30 students scored:
67, 69, 71, 72, 73, 74, 75, 76, 77, 78,
79, 80, 81, 82, 83, 84, 85, 85, 86, 87,
88, 88, 89, 90, 91, 92, 93, 94, 95, 96
Step 1: Find the range. Min = 67, Max = 96. Range = 29.
Step 2: Choose bins. Square root of 30 ≈ 5.5, so try 6 bins. Bin width = 29 ÷ 6 ≈ 5.
Step 3: Create bins and count:
| Bin | Range | Count |
|---|---|---|
| 1 | 67–71 | 3 |
| 2 | 72–76 | 5 |
| 3 | 77–81 | 5 |
| 4 | 82–86 | 5 |
| 5 | 87–91 | 6 |
| 6 | 92–96 | 6 |
Step 4: Interpret. The distribution is roughly uniform to slightly right-heavy, meaning scores are spread fairly evenly with a small concentration at the high end. No obvious outliers, no gaps.
Summary statistics:
- Mean: 82.5
- Median: 82.5
- Standard deviation: 8.4
The histogram confirms what the statistics suggest: a fairly symmetric, evenly spread distribution.
Common Mistakes
Mistake 1: Using a histogram for categorical data
If your data is "Product A: 50 sales, Product B: 30 sales, Product C: 70 sales," use a bar chart. Histograms are for continuous numerical ranges.
Mistake 2: Ignoring the bin count
The default bin count in many tools is arbitrary. Always experiment with different values. The "right" number of bins is the one that reveals the pattern without adding noise.
Mistake 3: Comparing histograms with different bin widths
If you're comparing two datasets, use the same bin edges. Different bin widths make visual comparison misleading.
Mistake 4: Confusing frequency with density
In a standard histogram, bar height = count (frequency). In a density histogram, bar height is adjusted so the total area equals 1. Density histograms are useful for comparing datasets of different sizes, but they can confuse readers who expect raw counts.
Mistake 5: Drawing conclusions from small samples
A histogram of 10 data points tells you very little about the underlying distribution. With small samples, the shape is dominated by random variation. As a rough guide, you need at least 30–50 data points before histogram shapes become meaningful.
When to Use a Histogram vs Other Charts
| Question you're asking | Best chart |
|---|---|
| "How is my data distributed?" | Histogram |
| "How do two distributions compare?" | Two histograms (same bins) or a box plot |
| "How does a value relate to another?" | Scatter plot |
| "How does a value change over time?" | Line chart |
| "How do categories compare?" | Bar chart |
Frequently Asked Questions
What is a histogram used for?
A histogram shows the frequency distribution of continuous numerical data. It's used to identify patterns like clustering, skewness, outliers, and gaps. Common applications include quality control, exam score analysis, scientific research, financial analysis, and any situation where understanding the shape of data matters.
How is a histogram different from a bar chart?
Histograms display continuous numerical data with adjacent bars (no gaps) representing ranges. Bar charts display categorical data with separated bars. In a histogram, the x-axis is a number line and bar order is fixed. In a bar chart, the x-axis has category labels and bars can be reordered.
What does a skewed histogram mean?
A right-skewed histogram has a long tail to the right — most values are low, with a few very high values pulling the mean above the median. Income distributions are a classic example. A left-skewed histogram has a long tail to the left — most values are high, with a few low values.
How many bins should a histogram have?
There is no single correct answer. Start with the square root of your data count (√n). For 100 data points, start with 10 bins. Then adjust: increase bins if the shape looks oversimplified, decrease if it looks noisy. The goal is to reveal the distribution shape without creating artificial patterns.
What is bin width in a histogram?
Bin width is the range of values each bar covers. It equals (max value − min value) ÷ number of bins. Wider bins create smoother charts with less detail. Narrower bins show more detail but can introduce noise. All bins in a standard histogram have equal width.
Can a histogram have gaps between bars?
Yes. Gaps indicate that no data points fall in that range. This can mean the data has distinct clusters, or it can be an artifact of having too many bins for the amount of data. A gap between two populated regions often suggests two separate subgroups.
What does a bimodal histogram indicate?
A bimodal histogram has two distinct peaks, suggesting the data contains two separate groups. For example, a histogram of heights for a mixed group of adults and children would show two peaks. Identifying bimodality is important because it means the mean is not representative of either group.
What is the difference between frequency and relative frequency in a histogram?
Frequency is the raw count of values in each bin. Relative frequency is the proportion (count ÷ total), often shown as a percentage. Relative frequency histograms are useful when comparing datasets of different sizes because the y-axis is normalized.
How do I create a histogram from my data?
Enter your numerical data (separated by commas, spaces, or newlines) into a histogram generator, choose a bin count, and review the shape. Most tools also calculate summary statistics like mean, median, and standard deviation alongside the chart.
Why does changing the number of bins change the shape?
Each bin count creates a different level of "resolution." Fewer bins smooth out variation, potentially hiding real features. More bins preserve detail but amplify random noise. The underlying data doesn't change — only how it's grouped for display.
Can I use a histogram for time-series data?
Histograms are not designed for time-series data because they don't preserve the order of values. A histogram of daily temperatures shows the distribution of temperatures but not when they occurred. For time-ordered data, use a line chart. You can use a histogram alongside a time-series chart to understand both the trend and the distribution.
What statistics should I look at alongside a histogram?
The most useful summary statistics to pair with a histogram are: mean (average), median (middle value), standard deviation (spread), min/max (range), and skewness (asymmetry). The histogram shows what these numbers look like in practice.