What is a histogram?
A histogram is a chart that shows how often values fall inside specific numeric ranges. You take a list of numbers, slice the range into equal-width buckets (called bins), count how many values land in each bin, and draw a bar for each one. The taller the bar, the more values that bin caught. The shape of the bars together tells you what the data looks like — whether it clusters in the middle, leans to one side, has two peaks, or spreads out evenly.
It's the chart statisticians reach for when they want to understand the shape of a distribution. Test scores from a class. Heights of a sample group. Daily temperatures over a year. Wait times at a call center. Anything continuous and numeric.
People mix up histograms with bar charts because they look similar. They are not the same. A bar chart shows categorical data — colors, brands, country names — with gaps between the bars because the categories are separate. A histogram shows continuous data with the bars touching, because the ranges flow into each other. If the x-axis has numbers and the bars touch, it's a histogram. If the x-axis has labels and the bars have gaps, it's a bar chart.
How to use the Histogram Maker
Drop your numbers into the input field. Separate them with commas, spaces, line breaks, or any mix of the three — the parser handles all of them. Non-numeric junk gets ignored, so pasting from a spreadsheet column with a header row works fine.
- Paste or type your numeric data into the textarea
- Adjust the bins slider until the shape of the distribution makes sense (more on this below)
- Read the bar heights and the count labels that appear above each bar
- Look at the bin labels under the chart to see which range each bar covers
The chart redraws instantly as you change the slider. Nothing leaves your browser — the calculation runs locally in JavaScript, so the numbers you paste are not sent to any server, logged, or stored.
Picking the right number of bins
This is the one decision that matters. Too few bins and the histogram smooths over real features in the data — a bimodal distribution will look like a single hump. Too many bins and every bar is one or two values tall, so you see noise instead of shape. The sweet spot depends on the size of your dataset and how it's distributed.
Statisticians have worked out several formulas for picking a starting number of bins. None of them is universally correct, but each has a use case.
| Rule | Formula | When to use it |
|---|---|---|
| Square root | k = √n | The simplest default. Works fine for small to medium datasets where you don't want to think. |
| Sturges | k = ⌈log₂(n) + 1⌉ | The classic textbook rule. Designed for roughly normal data with fewer than a few hundred values. Underbins large datasets. |
| Rice | k = ⌈2 · n^(1/3)⌉ | A more aggressive alternative to Sturges. Tends to suggest more bins, which helps when the distribution has fine structure. |
| Scott | h = 3.5 · σ / n^(1/3) | Computes bin width directly from the standard deviation. Good for data that's close to normal. |
| Freedman-Diaconis | h = 2 · IQR / n^(1/3) | Uses the interquartile range instead of standard deviation, which makes it less sensitive to outliers. Default in most serious statistical software. |
For most everyday use, start with Sturges or the square root rule and adjust the slider until the chart tells a clear story. If your data has a long tail or extreme outliers, Freedman-Diaconis is more honest about the bulk of the distribution.
A worked example: test scores
Suppose you've got 30 test scores from a class:
62, 75, 81, 88, 71, 69, 84, 77, 90, 65, 73, 79, 82, 86, 70, 74, 78, 85, 91, 67, 72, 80, 83, 87, 76, 89, 68, 81, 74, 79
Range: 62 to 91, so the spread is 29 points. With 30 values, Sturges gives us ⌈log₂(30) + 1⌉ = ⌈4.91 + 1⌉ = 6 bins. Each bin covers 29 / 6 ≈ 4.83 points.
| Bin range | Count | Bar (visual) |
|---|---|---|
| 62.0 – 66.8 | 2 | ██ |
| 66.8 – 71.7 | 5 | █████ |
| 71.7 – 76.5 | 6 | ██████ |
| 76.5 – 81.4 | 8 | ████████ |
| 81.4 – 86.2 | 5 | █████ |
| 86.2 – 91.0 | 4 | ████ |
The peak is in the 76.5 – 81.4 bin with 8 students, and the distribution is roughly bell-shaped with a slight left lean. That's a reasonable read for a test that landed near the difficulty target — most students clustered in the high 70s, fewer in the extremes.
Now drag the bins slider to 12. Each bar shrinks, and you start seeing zero-count bins. With only 30 values across 12 bins, you've over-resolved the data — you're now drawing the noise, not the shape. Drag it back to 3 and the histogram becomes uselessly coarse: just three bars, "low, middle, high." Six is the right answer for this set, which is exactly what Sturges suggested.
Reading distribution shapes
Once you have a clean histogram, the shape tells you something useful.
- Bell-shaped (normal) — symmetric, peaks in the middle, tapers in both directions. Common in measurements influenced by many small independent factors: heights, IQ scores, daily commute times.
- Skewed right (positive) — most values low, with a long tail trailing to the right. Income data, response times, and earthquake magnitudes typically look like this. The mean sits well above the median.
- Skewed left (negative) — long tail to the left. Less common; you see it in age-at-death data and exam scores when most students did well.
- Bimodal — two distinct peaks. Usually means you're looking at two overlapping populations. Heights of adults mixed together regardless of sex tend to show a bimodal pattern.
- Uniform — every bin has roughly the same count. Either the underlying process really is uniform (random number generators) or you're looking at way too few bins.
If the shape doesn't match what you expected, that's the histogram doing its job. A salary review where the distribution is bimodal is telling you something about who's getting paid what.
What histograms don't tell you
A histogram is a summary, and summaries lose information. It shows you the shape but not the individual values. Two datasets with very different specifics can produce nearly identical histograms — same mean, same spread, same general shape, but different stories underneath.
A few things a histogram can't show you:
- Order or time — if your data is a time series (daily stock prices, monthly sales), the histogram throws away the order. Use a line chart for that.
- Relationships between variables — a histogram is one-dimensional. To see how two numeric variables relate, use a scatter plot.
- Outliers in detail — a single outlier in a bin of 100 values disappears into the bar. If outliers are what you care about, a box plot or strip plot is better.
- The exact mean or median — you can estimate them from the shape, but for the precise value you need the underlying numbers (try the Average Calculator).
Use the histogram for the question it answers well: what does the spread of this data look like, and where are the values clustered?
Related tools
Histograms work best as part of a broader look at your data. A few companions:
- Average Calculator — mean, median, and mode for the same data you just plotted. Reading them alongside the histogram tells you which summary statistic actually fits.
- Z-Score Calculator — once you see the shape is roughly normal, the z-score tells you how far a specific value sits from the mean in standard-deviation units.
- Density Calculator — different kind of density, but the kernel density estimate is the smoothed cousin of the histogram for distributions.
Frequently asked questions
How many data points do I need to make a useful histogram?
At least 20 or 30. With fewer than that the bar heights are noisy enough that the shape isn't reliable. Below 10 values, a dot plot or a sorted list is usually more honest. The Histogram Maker will still draw a chart for a tiny dataset, but treat the result as suggestive rather than conclusive.
Should the bins all be the same width?
Yes, in almost every case. The Histogram Maker uses equal-width bins, which is the standard. Variable-width bins exist for specialized cases (like log-scale histograms for data spanning many orders of magnitude), but they make comparison between bins harder and most readers misinterpret them.
What's the difference between a histogram and a frequency distribution?
A frequency distribution is the table — bin ranges and counts. A histogram is the chart you draw from that table. They contain the same information; the histogram just makes the shape easier to see at a glance.
Can I make a histogram in Excel or Google Sheets?
You can, but it takes more setup than it should. Excel needs you to either install the Analysis ToolPak or use the FREQUENCY array formula, then build a bar chart from the result. Google Sheets has a histogram chart type buried in the chart editor. Both work, but for a quick look at a paste of numbers, opening a tab and pasting into a single field is faster.
Why does my histogram look different when I change the bin count?
Because the histogram is a lossy summary of your data, and the bin count controls how lossy. With few bins you see a smooth overall shape; with many bins you see local detail. The data hasn't changed — your view of it has. Try three or four different bin counts and pick the one where the chart tells the most honest story.
Does the Histogram Maker work with negative numbers or decimals?
Yes. Any real number works — positive, negative, integer, or decimal. The bin boundaries adjust to your data's actual range. A dataset like -2.5, 0, 3.1, 7.8 gets the same treatment as 25, 30, 35, 40.
Why are some bins showing zero?
Because the data has gaps. Either your dataset really has no values in that range (a bimodal distribution between two clusters), or your bin count is high enough relative to your data size that empty bins are inevitable. Reducing the bin count fills the gaps; keeping it high preserves the shape detail.
What if my data is categorical, like colors or brands?
Don't use a histogram. Histograms are for continuous numeric data only. For categorical data, use a bar chart with gaps between the bars and one bar per category. The visual difference signals to readers that the categories aren't on a numeric scale.