DATA VISUALIZATION · CHART SELECTION

A pie chart shows how one total splits into parts, using slices of a circle. A bar chart compares values across categories, using bars of different length. The short answer: make a bar chart by default, and switch to a pie chart only when the parts add up to a whole, you have about five slices or fewer, and the reader cares more about each share than about an exact ranking.

The two get mixed up because they start from the same table: one column of categories and one column of numbers. What differs is the question each chart answers. A pie asks "how much of the whole is this?" A bar asks "which is bigger, and by how much?" This guide draws the same data both ways, explains when each one earns its place, and ends with a checklist you can run in a minute. It is part of our wider data visualization guides, and if you are still weighing other chart families, start with how to choose a chart type.

Pie Chart vs Bar Chart at a Glance

  • Pie chart One whole split into parts; shows share of total and one dominant slice
  • Bar chart Any numeric value per category; shows ranking, gaps and exact differences
  • Must sum to 100%? A pie chart, yes. A bar chart, no
  • Number of categories Pie works up to about five; bars stay readable with a dozen or more
  • Close values Slices of 19% and 21% look the same; bars of 19 and 21 do not
  • Default choice Bar chart. Pick a pie only when the part-to-whole message is the point
Left panel: pie chart of 2,000 monthly website visits split into six channels. Right panel: horizontal bar chart of the same six channels sorted from 42 percent organic search to 4 percent paid
The same six numbers, drawn two ways. The data is hypothetical.

What Is a Pie Chart?

A pie chart, also called a pie graph or circle graph, is a circle cut into slices. Each slice is one category, and its size shows that category's share of the total. Atlassian's guide puts the requirement plainly: you need a whole amount that is divided into distinct parts (Atlassian). Datawrapper says the same thing from the tool side, a pie always represents a whole, which means 100% (Datawrapper).

That requirement is also the chart's weakness. Anything that does not add up to one whole, such as averages, scores or survey answers where people could pick several options, does not belong in a pie. You can build one from your own file with the free pie chart maker.

What Is a Bar Chart?

A bar chart, or bar graph, draws one bar per category, and the bar's length shows the value. Bars can run horizontally or vertically, and they can be grouped or stacked. The values can be counts, averages, rates, money or anything else on a numeric scale, so a bar chart accepts far more kinds of data than a pie does. Readers compare bars by looking at where each one ends against a shared baseline.

Our guide on how to make a bar graph covers the steps, bar chart vs column chart explains the orientation question, and the bar chart maker lets you try it on your own numbers.

Key Differences Between a Pie Chart and a Bar Chart

Pie chart versus bar chart
FeaturePie chartBar chart
Main jobShow each part's share of one wholeCompare values across categories
Question it answersHow much of the total is this?Which is bigger, and by how much?
Values must add to 100%?YesNo
Categories it handlesAbout 2 to 5A few to dozens
Close valuesHard to tell apartEasy to tell apart
RankingNeeds labels or careful readingVisible at a glance when sorted
Negative valuesNot possiblePossible
Several groups side by sidePoor; readers compare angles across piesGood with grouped or stacked bars
Typical examplesBudget split, market share with a clear leader, yes/no resultsSales by region, scores by team, survey results by option

Atlassian's comparison guide sums up the trade: bars handle a wider range of data and pack in more information, while a pie's one advantage is the immediate sense of a part-to-whole split (Atlassian).

Same Data, Two Charts: What Changes?

Say a site had 2,000 visits last month, split by channel: organic search 840, direct 420, social 300, email 240, referral 120 and paid 80. As shares, that is 42%, 21%, 15%, 12%, 6% and 4%, which add up to 100%.

In the pie, you see at once that organic search is a bit under half. That is the one message the pie delivers well. But try to answer a second question: is social bigger than email? Both slices are mid-sized, the colors differ, and you have to read the labels to be sure. Referral and paid are thin wedges whose labels need leader lines. In the bar chart, the order is obvious and the 3-point gap between social and email is visible without reading a single number.

  • 2,000Monthly visits
  • 6Categories
  • 42%Largest share

To get these totals from a raw export, build a summary first. The pivot table guide and the pivot table maker do that, and the frequency table maker counts categories directly (see also frequency distribution tables).

Why Bar Charts Win When Values Are Close

Now take five regions with sales shares of 22%, 21%, 20%, 19% and 18%. On a pie, every slice looks roughly one fifth. On a bar chart that starts at zero, the order from North down to Central is plain.

Left: pie chart with five regions at 22, 21, 20, 19 and 18 percent that look almost equal. Right: the same five values as sorted horizontal bars where the order is clear
Five similar shares. Even with labels, the pie makes you read every number to rank them. Hypothetical data.

There is research behind this. In the classic experiments by Cleveland and McGill, judging position along a common scale was the most accurate task, followed by length, then angle, then area. A later review notes that the accuracy gaps were often small, one or two points in a hundred (SAGE Journals). So a pie is not hopeless. It just asks readers to do a slightly harder job, and when the values are close, that harder job is where mistakes creep in.

Researchers also disagree about what people actually read in a pie. Kosara's studies found little evidence that the center angle is the main cue, and a later experiment on 3D pies pointed to area as the most likely one (Kosara, Tableau Research). The practical lesson does not change: if readers must rank or compare similar values, give them bars.

When to Use a Pie Chart

A pie chart works when most of these are true:

  • The slices add up to one real whole. Budget, time spent, votes cast, or a single population split into groups.
  • There are two to five categories. Tableau's chart guide uses that same range (Tableau).
  • One slice clearly leads, or the message is "about half" or "a small fraction."
  • The audience wants the big picture, not exact figures. Slides and executive summaries are the usual home.
  • You can label slices directly, so nobody has to match colors to a legend.

Observable's write-up makes the fair point that part-to-whole comparison is what pies are good at, and few other charts offer it in the same way (Observable). A two-part split is the cleanest case. Compare the pie below with a single 100% stacked bar: both show that mobile is 72% of sessions, and the bar has the advantage of easy-to-find quarter marks.

Left: pie chart with mobile at 72 percent and desktop at 28 percent. Right: a single horizontal bar of full width split into the same two parts with a 0 to 100 percent axis
A two-part split works in either form. Hypothetical data.

When to Use a Bar Chart

Pick a bar chart when any of these apply, which is most of the time:

  • You want to compare categories, or rank them from highest to lowest.
  • The values are not shares of one total. Averages, scores, prices, counts from different groups.
  • There are more than five categories, or the labels are long. Horizontal bars handle long names well.
  • The values are close, and the differences matter.
  • You want to compare several groups. Grouped bars put two or three series side by side, and a stacked bar adds up the parts.
  • Some values are negative, such as profit and loss.

If your categories are time periods rather than labels, the better comparison is bars against a line, covered in line graph vs bar chart. For a continuous measure grouped into ranges, see histogram vs bar graph.

How Many Slices Is Too Many?

Sources give slightly different limits, and none of them is a law. Tableau suggests two to five categories. Datawrapper says that with more than five parts you should group small ones or use a bar chart instead (Datawrapper). Our rule of thumb: stay at five or fewer, and if you have more, fold the smallest ones into an "Other" slice.

Keep two cautions in mind. First, "Other" should not become the largest slice, or the chart hides what it was built to show. Second, the limit is lower when slices are similar in size. Six slices of very different sizes can be readable; five slices of about 20% each cannot be ranked by eye.

When a Pie Chart Is the Wrong Choice

Atlassian lists several situations where a pie misleads, and they are worth knowing by heart (Atlassian):

  • The values do not sum to a whole. Survey questions that let people choose several answers produce shares that add past 100%. A circle implies a total that does not exist.
  • The values are averages. The average of the parts is not the average of the whole, so slices of averages mean nothing.
  • You are comparing groups. Two pies side by side force readers to compare angles across charts. A grouped or stacked bar is easier.
  • You are tracking change over time. Use a line or bars.
Horizontal bars for four apps with usage rates of 78, 64, 52 and 41 percent, with a note that they total 235 percent and cannot be slices of one pie
Respondents could pick more than one app, so the shares add to 235%. Hypothetical data.

Also avoid 3D pies and exploded slices. Tableau warns that tilting the pie skews how slice sizes are perceived. Our post on common data visualization mistakes lists more traps like these.

Alternatives to a Pie Chart

  • Sorted bar chart. The safest swap. Shows shares as lengths and ranks them.
  • 100% stacked bar. Keeps the whole in one bar and works well when comparing several groups.
  • Donut chart. A pie with a hole. Same limits on categories, and a spot in the middle for a total.
  • Treemap. Good when you have many categories and nested groups.
  • Waffle chart. A 10 by 10 grid where each square is 1%. Easy to read for round percentages.
  • A plain table. When the exact numbers matter more than the picture.

Atlassian calls the stacked bar a strong rival to the pie for part-to-whole work, since one bar is a pie's slices rolled out flat.

Are Pie Charts Actually Bad?

The "pie charts are bad" argument is partly right and partly overblown. The fair version goes like this. Pies are bad at precise comparison, bad with many slices, and often used on data that is not a whole. They are fine at showing one dominant share or a simple split, and many readers find them quick to grasp. Observable's article takes this middle position: dislike pies if you want, but base it on what is known about them (Observable).

So the useful question is not "pie or no pie" but "what must the reader take away?" If it is "organic search is nearly half of traffic," a pie can do it. If it is "social beats email by three points," only a bar will.

A Quick Decision Checklist

  1. Name the message. "Share of a total" points to a pie or stacked bar. "Which is larger" points to bars.
  2. Check the sum. If the values do not add to a meaningful 100%, use bars.
  3. Count the categories. More than five, use bars (or group the tail into "Other").
  4. Look at the gaps. If two values are within a few points of each other and the difference matters, use bars.
  5. Think about the audience. A quick slide for a general audience tolerates a pie. An analysis people will study does not.
  6. Plot both and compare. If the pie needs a legend and six callouts, the bar chart is the better one.
Flowchart: if the x-axis is time use a line graph; if values do not add to 100 percent use a bar chart; if there are more than five categories use a bar chart; if readers must compare close values use a bar chart; otherwise a pie chart is fine
The checklist as a flow. It is a guide, not a law.

How to Make Each Chart in Excel, Sheets and Python

Excel. Select your two columns. For a pie, choose Insert, then Insert Pie or Doughnut Chart. For bars, choose Insert, then Insert Column or Bar Chart. To switch, select the chart and use Chart Design, then Change Chart Type. Sort the data (Data, then Sort) before you build the bar chart so the bars come out in order.

Google Sheets. Select the data, choose Insert, then Chart, and change the chart type in the Setup tab to Pie chart or Bar chart. Menu names shift between versions, so check the current interface if yours differs.

Python (matplotlib). Both charts take a few lines, and you can draw them side by side to compare:

import matplotlib.pyplot as plt

channels = ["Organic search", "Direct", "Social", "Email", "Referral", "Paid"]
visits   = [840, 420, 300, 240, 120, 80]
share    = [v / sum(visits) * 100 for v in visits]

fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(11, 4.5))

ax1.pie(visits, labels=channels, autopct="%1.0f%%",
        startangle=90, counterclock=False)       # pie chart
ax1.set_title("Pie chart")

ax2.barh(channels[::-1], share[::-1])            # largest bar on top
for y, p in enumerate(share[::-1]):
    ax2.text(p + 0.5, y, f"{p:.0f}%", va="center")
ax2.set_xlabel("Share of visits (%)")
ax2.set_title("Bar chart")

plt.tight_layout()
plt.show()

If you would rather skip the code, upload a CSV to AmriData's data visualization features or ask for a chart in plain English with AI data chat. If you are building a report, the analysis dashboard guide and KPI examples show where share-of-total charts fit.

Pie Chart vs Bar Graph in School and Exams

Students usually meet this as "pie chart vs bar graph," often in math, science or a data handling unit. Two skills come up again and again.

Drawing a pie by hand. Each slice's angle is its share of 360 degrees. In our traffic example, organic search is 840 out of 2,000, which is 42%, and 0.42 × 360 = 151.2°. Direct is 75.6°, social 54°, email 43.2°, referral 21.6° and paid 14.4°. Those six angles add to 360°, which is a good check on your arithmetic.

Describing a chart in words. For a pie, name the whole, the largest and smallest slices, and use fractions: "Organic search makes up a little over two fifths of all visits, and paid makes up the smallest share at 4%." For a bar graph, name the highest and lowest bars, give the gap between them, and mention the unit. Follow your teacher's rubric if it asks for something different.

A bar graph is usually the right choice for comparing separate groups, such as the number of students who chose each sport. A pie is the right choice for showing how a class of 30 divides into a few groups. The frequency table comes first in either case, because the counts feed both charts.

Common Pie Chart and Bar Chart Mistakes

  • Using a pie for values that do not total a whole. Multi-answer survey results are the usual culprit.
  • Too many slices. Past five or six, the labels collide and the colors blur.
  • Leaving slices unsorted. Order them by size, clockwise from the top, unless the categories have a natural order.
  • 3D effects and exploded slices. They change how big a slice looks.
  • Relying on a legend. Label slices and bars directly so readers do not have to match colors.
  • Starting a bar chart axis above zero. Bar length is the data, so a cut-off baseline exaggerates differences.
  • Leaving bars in random order. Sort from high to low unless the categories have a fixed order such as months.
  • Showing percentages that do not add to 100. Rounding can cause 99% or 101%; add a note rather than leave it unexplained.

Practice Questions With Answers

1. A household budget split into rent, food, transport and savings. Which chart?

Pie chart or a stacked bar. The parts make a whole and there are only four.

2. Average test score for eight classes. Which chart?

Bar chart. Averages are not parts of a whole, and eight categories is too many for a pie.

3. A survey asks which of five apps people use, and respondents can pick several. Which chart?

Bar chart. The shares add to more than 100%, so a pie would be wrong.

4. Five regions with sales shares between 18% and 22%. Which chart?

Sorted bar chart. The values are close and the ranking matters.

5. 72% of visitors use mobile and 28% use desktop. Which chart?

Either. A two-part split suits a pie, and a 100% stacked bar works just as well.

6. Monthly revenue for two years. Which chart?

Neither. Use a line graph, or columns if you want to compare individual months.

Try Both Charts on Your Own Data

The fastest way to settle the choice is to look at both. Paste your numbers into the pie chart maker and the bar chart maker, then ask which one answers your question sooner. For vertical bars, the column chart maker is the matching tool, and the frequency table maker prepares counts when your data is a raw list.

Frequently Asked Questions About Pie Charts and Bar Charts

What is the difference between a pie chart and a bar chart?

A pie chart shows how a whole splits into parts, with each slice's size showing its share. A bar chart compares values across categories using bar length. The pie answers "how much of the total," and the bar answers "which is bigger."

When should I use a pie chart instead of a bar chart?

Use a pie when the values add up to one whole, you have about five slices or fewer, and the main message is a share, such as "nearly half." Otherwise use a bar chart.

Why are bar charts better than pie charts?

Readers compare bar lengths against a common baseline more accurately than they compare angles or areas, and bars handle more categories and more kinds of data. The accuracy gap is often small, but it grows when values are close.

Are pie charts bad?

Not always. They are poor for precise comparison, many categories and data that is not a whole. They work for simple splits with one clear leader.

How many slices should a pie chart have?

Five or fewer is a common guideline. If you have more, group the smallest into "Other" or use a bar chart.

Does a pie chart have to add up to 100%?

Yes. The circle stands for a whole, so the slices should add to 100% of that whole. If they do not, use a bar chart.

Can a bar chart show percentages?

Yes. Bars can show percentages, and they do not need to add to 100%. A 100% stacked bar shows parts of a whole in a single bar.

Can a pie chart show change over time?

Poorly. Two pies side by side make readers compare angles across charts. A line graph or grouped bars show change much more clearly.

Which is better for survey results, a pie chart or a bar chart?

A bar chart, in most cases. Survey questions that allow several answers produce shares above 100%, which a pie cannot show. A pie is fine for a single-choice question with a few options.

What is a better alternative to a pie chart?

A sorted bar chart is the safest swap. A 100% stacked bar, a treemap or a waffle chart also work for part-to-whole data.

Is a pie graph the same as a pie chart?

Yes. Pie graph, pie chart and circle graph are different names for the same chart. In the same way, bar graph and bar chart mean the same thing.

How do I calculate the angle of a pie chart slice?

Divide the slice's value by the total and multiply by 360. A slice of 42% is 0.42 × 360 = 151.2 degrees.

Key Takeaways

  • Pie charts show share of a whole; bar charts compare values. Decide which question you are answering.
  • Use a pie only when slices add to 100%, there are about five or fewer, and one message is the point.
  • When values are close or you need a ranking, a sorted bar chart is clearer.
  • Multi-answer survey data and averages never belong in a pie.
  • A 100% stacked bar is the best bridge between the two.
  • When unsure, plot both and keep the one that makes your point faster.

Bottom line: The right chart is the one that lets a reader reach the correct conclusion without help. For more chart guidance, browse the full data visualization category.

Further Reading and Sources