To create a tree map chart in Excel for Microsoft 365 on Windows, arrange your data in columns from broad category to specific category, with a numeric value in the last column; select the data, then choose Insert > Insert Hierarchy Chart > Treemap. Excel displays the values as nested rectangles, with larger rectangles representing larger totals.
What a tree map chart shows
A treemap, also called a tree map, is a chart for comparing parts of a whole when the data has a hierarchy. Each rectangle represents a category, and smaller rectangles can represent categories within it. The area of a rectangle is proportional to its value relative to the other values in the same chart. For example, a treemap can show total company revenue by division, then by product within each division.
Unlike a column chart, a treemap does not use a horizontal and vertical axis. Its nested layout makes it possible to display many categories in a compact area, while the hierarchy shows which items belong together. It is most useful for spotting large contributors and broad patterns. It is less suited to reading precise values or comparing two similarly sized rectangles by eye.
Excel introduced the Treemap chart type in Excel 2016. In Microsoft 365 for Windows, it is available from the Insert tab. The Mac interface may arrange chart controls somewhat differently, but the Treemap chart type is available in current desktop Excel editions. If the command is missing in Excel for the web or an older installation, open the workbook in an up-to-date desktop version of Excel.
Prepare the data as a hierarchy
Set up the source data as a simple table: one column for each level of the hierarchy, followed by one column of values. Use a header row, and put one lowest-level item on each data row. For instance, a sales table might have Division, Product, and Revenue columns. The Division and Product fields describe the nesting; Revenue determines rectangle size.
- Use clear, nonblank column headings, such as Region, Store, and Sales.
- Repeat parent names on each row rather than inserting merged cells or blank spacer rows.
- Keep the values numeric and use one consistent unit, such as dollars or units sold.
- Do not include grand-total or subtotal rows in the selected source range. Those values would be counted alongside the underlying records.
- Check for spelling variations in category names; Excel treats different text as different categories.
For example, a table with Division, Product, and Revenue might contain rows for Home / Lamps / 12,000, Home / Chairs / 18,000, and Outdoor / Grills / 25,000. Excel groups the products under their divisions and sizes their rectangles by revenue. If you include a total for Home as another row as well as the two product amounts, the chart may overstate that division because the same revenue has been counted twice.
Convert the range to an Excel table with Insert > Table if the source will grow over time. A table can make it easier to keep the chart’s source data current as rows are added, though it is still worth checking the selected chart data after major changes. Avoid using a separate column containing a precomputed overall total unless that column is the value field you actually intend to plot.
Create a treemap in Excel
- Click a cell in the prepared data or select the complete range, including the headings.
- Choose Insert > Insert Hierarchy Chart > Treemap. In some ribbon layouts, the hierarchy-chart button is grouped with other chart types on the Insert tab.
- Review the chart. Check that the hierarchy is grouped as intended and that the largest rectangles correspond to the largest values.
- Use the chart title and data labels to make the result understandable to someone who has not seen the source table.
If Excel arranges levels in a surprising way, first inspect the source columns and their order. The first category column should be the broadest level, followed by increasingly specific fields, with the numeric measure at the end. You can also select the chart and use Chart Design > Select Data to review its source range. For a substantially different hierarchy, it is often clearer to correct the source layout and recreate the chart than to try to force an accidental grouping.
On Mac, select the source and use the Insert tab’s hierarchy chart options; exact grouping and ribbon presentation can vary by Excel release. Excel for the web can have a different feature set and interface from desktop Excel. When a workbook is intended for others to edit, verify that recipients’ versions support the chart type and retain its formatting.
How to interpret rectangles and labels
The size of a rectangle communicates magnitude, not rank order by itself. A large area means a large value compared with the other values in the same chart; it does not say that the category is important for every business purpose. In a two-level chart, the parent region occupies area based on the combined values of its children, and its child rectangles divide that area according to their own values.
Suppose North has stores with sales of 60 and 40, while South has stores with sales of 30 and 20. The whole chart represents 150 units: North accounts for 100 and South for 50. North therefore occupies about two-thirds of the total area, and its two stores divide North’s area in a 60-to-40 proportion. This nesting helps show both the overall share and the composition within a parent.
Labels can show category names and, depending on the available label options, values or other details. Small rectangles may not have enough room for readable text, so Excel can omit or crowd labels. A label’s displayed number should be checked against the source data if accuracy matters; the chart is not a substitute for a detailed table. A useful practice is to place a sorted source table near the chart or provide a filtered table for readers who need exact figures.
Format the chart for a clear message
Select the chart to expose its chart tabs. Use Chart Design > Add Chart Element to add or adjust elements such as the chart title and data labels. Chart Design > Change Colors offers color palettes, while the Format tab and formatting pane provide further controls for chart elements. Menu details can differ slightly between ribbon layouts and releases.
- Give the chart a specific title, such as “2025 Sales by Region and Store,” rather than leaving a generic title.
- Choose a restrained color palette. Too many strong colors can make a chart with many categories harder to scan.
- Use labels selectively. If labels overlap or become tiny, remove some, enlarge the chart, or show fewer hierarchy levels.
- Make the value unit clear in the title, a nearby note, or the source table—for example, revenue in thousands of dollars.
- Check contrast and text size at the actual display or print size, not only while zoomed in on the worksheet.
Treemap color is not automatically a second reliable scale for the value. Depending on the chart’s formatting and data, colors can distinguish categories or levels; do not assume a darker shade always means a larger value unless you have deliberately set up and explained that encoding. If the question is which categories are highest, add readable labels or pair the chart with a descending table or bar chart.
Common problems and practical fixes
A chart that looks empty or unexpected often traces back to its source range. Confirm that the numeric measure contains numbers rather than text that only looks numeric, that the range includes all the intended rows, and that header cells are included. Remove blank rows, unintended totals, and duplicate records where those records should not count more than once.
- Wrong grouping: Reorder the hierarchy columns from general to specific and ensure each row describes one leaf item.
- Repeated or duplicate areas: Check for subtotal rows, duplicate transactions, and repeated values that should first be summarized.
- Unhelpful labels: Make category names distinct where possible and add context when the same name appears under different parents.
- Unreadable small items: Filter to a relevant subset, group minor categories into a meaningful “Other” category before charting, or choose another chart type.
- Negative or zero values: A rectangle’s area cannot communicate a negative magnitude meaningfully. Treemaps are generally best for positive contributions; use a chart designed to show losses and gains when signs matter.
Be cautious about manually combining small categories into “Other.” Do so in a summarized copy of the data, not by deleting records from the underlying source, and make the grouping rule explicit. Otherwise, the chart can hide a meaningful item or make its totals difficult to reconcile. Likewise, changing filters or source rows can change every rectangle’s relative area, so record the date range and selection represented by the chart.
When a treemap is—and is not—the right choice
Choose a treemap when the main question is how a positive total is distributed across several nested categories, especially when there are too many items for a simple pie chart. It can reveal that one division dominates, or that a particular product accounts for much of its division’s sales. It is also compact, which can help on dashboards with limited space.
Choose a bar chart when readers must compare exact rankings or close values. Bar lengths aligned to a common baseline are easier to compare than rectangle areas. A stacked bar chart may be more appropriate when comparing category composition across a small number of groups. A sunburst chart is another Excel hierarchy chart and emphasizes levels in concentric rings; it can be useful when the hierarchy itself is the focus, though its segments can also be difficult to compare precisely. A table with conditional formatting may be preferable when exact values and labels matter more than an overview.
Treemaps are not the same as mind maps or organizational charts. Those diagrams show relationships or reporting structure, not quantitative shares. Nor is a treemap simply a colored table: rectangle area is tied to the selected numeric measure. Choosing the chart based on the question—share, ranking, trend, or structure—prevents a visually striking but misleading display.
Frequently Asked Questions
How do I create a tree map chart in Excel?
Select a table with hierarchy columns followed by a numeric value column, then choose Insert > Insert Hierarchy Chart > Treemap. Review the grouping, title, and labels after Excel creates it.
Can I make a treemap with two levels?
Yes. Use two category columns—for example, Department and Product—plus the numeric value column. Excel nests the product rectangles inside their department rectangles. One category level can also be used when a hierarchy is unnecessary.
Why is my treemap not showing all labels?
Excel may leave labels out when rectangles are too small to hold them legibly. Increase the chart size, reduce the number of displayed categories, or rely on a companion table for complete names and exact values.
Can a treemap show negative numbers?
A rectangle’s area represents size, so it cannot naturally indicate a negative contribution. For data containing gains and losses, use a chart that makes positive and negative directions explicit, such as a bar chart with a zero baseline.
Is a treemap available in Excel for Mac?
Current desktop Excel for Mac includes hierarchy chart options, including Treemap, though ribbon placement and formatting controls may differ from Windows. Availability and editing options in Excel for the web can vary, so use desktop Excel if the chart command is unavailable.
How is a treemap different from a sunburst chart?
Both can display hierarchical data. A treemap uses nested rectangles, while a sunburst uses concentric rings. Rectangles use screen area efficiently; rings make successive levels visually explicit. Neither is ideal for precise comparisons between similar-sized items, so consider a bar chart when ranking is the priority.
Related
- Resize Columns in Excel: Keyboard Shortcuts and Tips
- Remove Quotation Marks in Excel: Methods That Work
- Remove a Data Validation List in Excel: Steps and Fixes
Try it: the Percentage Formula Generator: percent of, percent change, increase and decrease, with the formula.
More in Charts & pivot tables
- Revenue Waterfall Chart in Excel: Build and Format OneTo make a revenue waterfall chart in Excel for Microsoft 365, put the opening revenue and each increase…
- 3D Pie Chart in Excel: How to Create and Format ItTo create a 3-D pie chart in Excel for Microsoft 365 on Windows, select a two-column list of…
- Excel Pivot Table: Group Dates by Year, Quarter & MonthYes. In Excel for Microsoft 365 on Windows, put a real date field in a PivotTable, right-click one…
- Excel Pivot Table: How to Filter by a List of ValuesFor a quick filter, open the PivotTable field’s drop-down, clear Select All, check the values you want, and…
- Monthly Excel Gantt Chart: Build a Clear Project TimelineA monthly Excel Gantt chart shows when tasks begin and end across a calendar, with colored cells marking…
- Create an Excel Dashboard With Free AI ToolsYes—you can create an Excel dashboard with free AI tools by asking a free AI assistant to help…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.