A histogram uses bars to show how numerical data are grouped into intervals. The data are split into equal-width intervals, called bins, and each bar’s height is the count of values in that interval. The bars touch, because the intervals are continuous, which is what distinguishes a histogram from a bar graph.
In Spanish
histograma
Also called
frequency histogram, histogram chart
How to say it
HIS-tuh-gram
Grade level
6-8
Grade 6Grade 7Grade 8Algebra 1CCSS 6.SP.B.4SATACT
Histogram in a picture
The histogram’s bars touch because 10–20 runs straight into 20–30 on the number line. The fruit bars have gaps because apple, pear and plum are separate categories.
Formal definition and notation
A histogram displays the distribution of one numerical variable. The number line is divided into adjacent intervals (bins or classes) of equal width, and over each interval a bar is drawn whose height equals the frequency, the number of data values in that interval (or the relative frequency, that count divided by the total). Each value belongs to exactly one bin; a common convention includes the left endpoint and excludes the right, so 30 goes in 30–40, not 20–30. Bars are contiguous, and an interval with no data has a gap of height 0.
Symbol
Read it as
Meaning
20–30
twenty to thirty
a bin from 20 up to (but usually not including) 30; bins of a histogram all have the same width
frequency
frequency
how many data values fall in a bin; it is the height of the bar
relative frequency
relative frequency
frequency divided by the total count, such as 720 = 35%
Key facts
A histogram is for numerical data (heights, times, scores). A bar graph is for categories (favorite fruit, eye color).
The bars touch because the bins cover the number line with no gaps. A space between bars means a bin with a count of 0.
You cannot read individual values from a histogram, only how many values fall in each interval.
The shape shows the distribution: symmetric (a single hump in the middle), skewed right (a long tail toward large values), skewed left, or with more than one peak. Gaps and outliers stand out too.
Changing the bin width can change how the histogram looks, so compare histograms only when they use the same bins.
How to build a histogram
How to build a histogram
bin width ≈ max − minnumber of bins, rounded to a friendly number
max, min
the largest and smallest data values
number of bins
often 5 to 15; more data allows more bins
frequency
count the values in each bin, then draw touching bars that high
For test scores from 62 to 97, 97 − 624 ≈ 9, so use a width of 10: 60–70, 70–80, 80–90, 90–100. Start the first bin at or below the smallest value.
Try it: make a histogram
Interactive
Edit the test scores or press Add a value. Each bar counts the scores in a bin of width 10 (the left edge is included). Switch to Dot plot to see the individual values behind the bars, then add an outlier.
This interactive needs JavaScript. The worked examples below show the same ideas step by step.
Histogram examples, step by step
Example 1: Read a histogram
Warm-up
A histogram of pages read has bars 0–10: 3 students, 10–20: 8 students, 20–30: 6 students, 30–40: 3 students. How many students are shown, and which interval is most common?
Each bar’s height is a count of students, so add the heights: 3 + 8 + 6 + 3.
3 + 8 = 11, 11 + 6 = 17, 17 + 3 = 20.
The tallest bar is 10–20, with 8 students.
Answer: 20 students are shown, and 10–20 pages is the most common interval.
Example 2: Build the frequency table
Core
Twelve people’s ages are 23, 35, 41, 28, 19, 33, 37, 45, 29, 31, 38 and 26. Make the counts for a histogram with bins 10–19, 20–29, 30–39 and 40–49.
10–19: only 19, so the count is 1.
20–29: 23, 28, 29 and 26, a count of 4.
30–39: 35, 33, 37, 31 and 38, a count of 5.
40–49: 41 and 45, a count of 2. Check: 1 + 4 + 5 + 2 = 12 people.
Answer: The bar heights are 1, 4, 5 and 2.
Example 3: A percent from a histogram
Test-style
A histogram shows the commute times of 40 workers: 0–15 minutes: 6, 15–30: 14, 30–45: 12, 45–60: 8. What percent of the workers commute 30 minutes or more?
“30 minutes or more” covers the bins 30–45 and 45–60 (30 is the left edge of 30–45).
Add those bars: 12 + 8 = 20 workers.
Divide by the total: 2040 = 0.5.
Trap: the histogram cannot tell you how many workers commute exactly 30 minutes, only how many fall in each interval.
Answer: 50% of the workers commute 30 minutes or more.
Common mistakes
✗ MistakeUsing a histogram for the number of students who chose each sport.
✓ InsteadUse a bar graph, with a separate bar for each sport and gaps between them.
A histogram is for numerical intervals, while a bar graph compares categories. Sports have no order on a number line, so the bars should not touch.
✗ MistakeThe 20–30 bar is 7 high, so the data value is 7.
✓ InsteadThe bar means 7 values lie between 20 and 30.
Bar height is a count (frequency), not a data value. The data values are on the horizontal axis, grouped into intervals.
✗ MistakePutting the value 30 in both the 20–30 bin and the 30–40 bin.
✓ InsteadPut 30 in the 30–40 bin only (left edge included).
Each value goes in exactly one bin, or the bar heights add up to more than the number of data values.
✗ MistakeReading the mean as the middle of the tallest bar.
✓ InsteadThe tallest bar is the most common interval. The mean needs the actual values (or an estimate from bin midpoints).
In a skewed histogram the mean and median sit away from the peak, toward the long tail.
A bar graph compares categories, so its bars are separate and can be in any order. A histogram groups numbers into intervals in number-line order, so its bars touch.
A line plot (dot plot) shows every single value as a dot or X above a number line. A histogram only shows how many values fall in each interval, so individual values disappear.
A box plot summarizes data with five numbers (minimum, quartiles, median, maximum). A histogram shows the full shape, including peaks and gaps that a box plot hides.
Quick check: 3 questions
Question 1 of 3
Which data set is best shown with a histogram?
Show answer and explanation
Answer: B. Heights are numerical and can be grouped into intervals such as 140–150 cm. Favorite colors and grade levels are categories (bar graph), and daily temperatures over time fit a line graph.
Question 2 of 3
A histogram of 25 test scores has bars 50–59: 4, 60–69: 7, 70–79: 9 and 80–89: 5. How many scores are 70 or higher?
Show answer and explanation
Answer: D. Add the 70–79 and 80–89 bars: 9 + 5 = 14. 9 counts only one bar, 16 adds the 60–69 and 70–79 bars, and 25 is everyone.
Question 3 of 3
For the same histogram (4, 7, 9, 5 scores), which interval contains the median?
Show answer and explanation
Answer: C. With 25 scores the median is the 13th. Counting up: 4 scores reach 59, 11 reach 69 and 20 reach 79, so the 13th is in 70–79. Choice B forgets that the first 4 scores come before it.
Histogram: frequently asked questions
What is the difference between a histogram and a bar graph?
A histogram shows numerical data grouped into equal intervals, in number-line order, with touching bars. A bar graph shows categories, such as favorite sports, with separate bars that can go in any order. Ask yourself: could the labels on the horizontal axis go on a number line? If yes, use a histogram.
How many bars should a histogram have?
There is no single rule. OpenStax notes that many histograms use five to 15 bars, and one guideline is to take the square root of the number of data values: about 6 bars for 36 values. Too few bars hide the shape; too many leave each bar with just one or two values. Use the same bin width for every bar.
What does the shape of a histogram tell you?
The shape describes the distribution. One hump in the middle with matching sides is symmetric, and the mean and median are close. A long tail to the right is skewed right, which pulls the mean above the median, as with incomes. Two humps can mean two groups are mixed together. Isolated bars far from the rest point to outliers.
Number LineA number line is a straight line with numbers placed at equal distances along it, so every point stands for a number. Zero sits in the middle, positive numbers go to the right and negative numbers to the left. Numbers increase from left to right, so a number line shows order, distance and adding as moving.Number System · Grade 2, Grade 3, Grade 6HeightHeight is how tall something is: the distance from its bottom to its top, measured straight up and down. In geometry, the height of a shape is the perpendicular distance from a base to the opposite vertex or side, so it always meets the base at a right angle. Area and volume formulas use it.Measurement · Grade 2, Grade 5, Grade 6NumberA number is an amount or value used to count, measure, order and compare. We write numbers with digits (7), words (seven) or other symbols, but the number itself is the amount: 7 dots, the word seven and the numeral 7 all show the same number. Numbers include whole numbers, fractions, decimals and negatives.Number System · Kindergarten, Grade 1, Grade 2DataData are facts or values collected to answer a question, such as survey answers, measurements or counts. Numerical data are numbers you measure or count, like heights; categorical data are labels or groups, like favorite colors. Data are organized in tables and shown in graphs so patterns are easy to see.Statistics · Grade 2, Grade 3, Grade 6Relative FrequencyRelative frequency is how often a value or event occurs compared with the total number of observations: frequency ÷ total. It can be a fraction, a decimal or a percent. If 12 of 40 students choose apples, the relative frequency of apples is 1240 = 0.3, or 30%. All the relative frequencies in a table add to 1.Statistics · Grade 7, Grade 8, StatisticsBar GraphA bar graph uses bars to compare amounts in different categories. The taller or longer the bar, the larger the value it represents. Each bar stands for one category, such as a favorite sport, and its length is read against a number scale. Bars can be vertical or horizontal, with gaps between them.Statistics · Grade 3, Grade 4, Grade 5OutlierAn outlier is a data value that is far away from most of the other values in a set. In 4, 5, 6, 7, 50, the value 50 is an outlier. A common test flags any value more than 1.5 times the interquartile range below the first quartile or above the third. Outliers pull the mean strongly.Statistics · Grade 6, Grade 7, Grade 8MidpointA midpoint is the point exactly halfway between the two endpoints of a line segment, so it splits the segment into two equal parts. On the coordinate plane, find it by averaging the coordinates: the midpoint of (x1, y1) and (x2, y2) is (x1 + x22, y1 + y22).Geometry · Grade 8, Algebra 1, GeometryMedianThe median is the middle value when data are listed in order. If there is an even number of values, the median is the average of the two middle values. Half the data lie at or below the median and half at or above it, and outliers barely move it.Statistics · Grade 5, Grade 6, Grade 7Line PlotA line plot shows data values along a number line, often with marks above each value. Each X or dot stands for one data value, and repeated values stack in a column, so the tallest stack is the mode. Line plots make it easy to see clusters, gaps, outliers and the spread of a small data set.Statistics · Grade 3, Grade 4, Grade 5Dot PlotA dot plot is a graph that shows each data value as a dot above its place on a number line. Dots for repeated values stack up in a column, so the tallest stack shows the mode, and you can see the center, spread, gaps and outliers of the data at a glance.Statistics · Grade 3, Grade 4, Grade 5Box PlotA box plot displays a data set through five numbers: minimum, first quartile, median, third quartile, and maximum. The box holds the middle half of the data, a line inside it marks the median, and whiskers reach out to the smallest and largest values. It makes spread easy to compare between sets.Statistics · Grade 6, Grade 7, Grade 8QuartileA quartile is one of three values that split an ordered data set into four parts with about the same number of values. The first quartile, Q1, is the median of the lower half; Q2 is the median of all the data; Q3 is the median of the upper half. The interquartile range is Q3 − Q1.Statistics · Grade 6, Grade 7, StatisticsSquare RootA square root of a number is a value that, multiplied by itself, gives that number. The square root of 36 is 6 because 6 × 6 = 36. Every positive number has two square roots, such as 6 and −6, but the radical sign √ means the principal square root, which is the non-negative one.Number System · Grade 8, Algebra 1SideA side is one of the straight line segments that form the outline of a polygon. Two sides meet at each corner, or vertex. A triangle has 3 sides and a square has 4, and adding the lengths of all the sides gives the perimeter.Geometry · Kindergarten, Grade 1, Grade 2RangeThe range of a data set is the difference between the greatest and least values: maximum minus minimum. For 2, 5, 9, the range is 9 − 2 = 7. Range is a simple measure of spread: it tells how far apart the extreme values are, though one outlier can make it misleading about the rest of the data.Statistics · Grade 5, Grade 6, Grade 7MeanThe mean is the sum of the values divided by the number of values. It is the arithmetic average: add every value and divide by how many there are. For 3, 7, 5 and 9, the mean is 24 ÷ 4 = 6. The mean is the balance point of the data, so one outlier can pull it far.Statistics · Grade 5, Grade 6, Grade 7Normal DistributionA normal distribution is a symmetric, bell-shaped distribution of data centered at the mean, where the mean, median and mode are equal. Its spread is set by the standard deviation σ. About 68% of values lie within 1σ of the mean, 95% within 2σ and 99.7% within 3σ. Heights and test scores are often close to normal.Statistics · Algebra 2, Statistics