Automatic Outline in Excel: How to Set It Up
In this article
Yes, Excel can outline your data automatically. If your worksheet is set up with summary rows or columns containing formulas (like SUBTOTAL or SUM), the Data > Group > Auto Outline command builds a collapsible outline in one click, adding the small plus/minus buttons and level numbers you see beside the grid. This guide shows you how to prepare the data, apply the automatic outline, and fix it when Excel refuses to cooperate. Menu labels can differ slightly between Excel versions and platforms; the steps below are for the desktop version on Windows and Mac.
What You'll Need
- Excel on desktop (Windows or Mac) — the Auto Outline command is not available in Excel for the web or the mobile apps, so do this on a computer
- A worksheet where each group of detail rows (or columns) is followed or preceded by a summary row containing a formula such as SUM, AVERAGE or SUBTOTAL
- No blank rows or columns inside the range you want outlined
Step-by-Step
- Structure your data first. Put detail rows together in blocks, with one summary row per block. Make sure every summary cell contains a formula that references the detail cells above or below it — Auto Outline detects groups by these formulas. If your summary rows sit below the details, you are fine; if they sit above, you will flip one setting in step 5.
- Remove blanks and merged cells. Delete any completely empty rows or columns inside the data range and unmerge any merged cells in the rows you want grouped, because both can break the automatic detection.
- Select the range. Click any single cell inside your data. If you want to outline only part of the sheet, select that specific range instead.
- Apply the automatic outline. Go to the Data tab on the ribbon and click Group > Auto Outline (on some versions it appears directly as Auto Outline in the Outline group). Excel immediately inserts the outline symbols.
- If your summary rows are above the details: click the small launcher arrow in the bottom-right corner of the Outline group on the Data tab to open the Settings dialog, uncheck "Summary rows below detail", click OK, and then run Auto Outline again.
- Collapse and expand groups. Use the minus (–) buttons beside the row numbers to collapse a group and plus (+) to expand it. The numbered buttons (1, 2, 3…) at the top-left of the sheet jump between outline levels — click 1 to see only top-level summaries.
- Manually adjust if needed. If a group was missed, select those rows, then click Data > Group > Group (or press Shift+Alt+Right Arrow on Windows). Use Data > Ungroup (Shift+Alt+Left Arrow) to remove a single group, or Ungroup > Clear Outline to remove the whole outline.
Common Mistakes
- Typing summary values instead of formulas. Auto Outline finds groups through formula relationships. Hand-typed totals are invisible to it.
- Blank rows inside groups. A single empty row can split a group or make the whole command fail with no visible explanation.
- Trying it in Excel for the web. The web version can display and expand existing outlines but has no Auto Outline command.
- Forgetting the summary position setting. If totals are above details and you leave "Summary rows below detail" checked, Excel groups the wrong rows or errors out.
- Expecting a heading-based outline. Auto Outline groups data by formulas, not by text headers. Headings alone will not create groups — use manual grouping for those rows.
Tips
- Use SUBTOTAL instead of SUM for summary rows if you also use filters — the two features work well together.
- Nest your summaries: a grand total that references other summary rows creates a second outline level automatically.
- Press Ctrl+8 to toggle the outline symbols on and off without removing the outline.
- Outlines survive saving; the collapsed/expanded state is saved with the file.
- Outline columns the same way — the command works horizontally if your summary column contains formulas referencing columns beside it.
Troubleshooting
"Cannot create an outline" or nothing happens: Excel found no formulas linking summary and detail cells. Check that totals are real formulas referencing the detail rows, remove blank rows inside the range, and try again.
Wrong rows get grouped: Your summary rows are probably above the details. Open the Outline group's dialog via the launcher arrow on the Data tab and change the "Summary rows below detail" setting, then clear and reapply the outline.
Outline symbols disappeared: Press Ctrl+8, or check File > Options > Advanced (Windows) and make sure "Show outline symbols" is enabled under the section for working with cells.
Grouped rows won't stay collapsed: You are probably filtering — sorting or filtering resets some outline views. Re-collapse after filtering.
Frequently Asked Questions
Does Auto Outline work in Excel for the web?
No. The web version can show and expand outlines created on desktop, but you cannot create or edit them there. Use the desktop app.
Can I outline based on text headings instead of formulas?
Not automatically. Auto Outline only detects formula-based summaries. Select the heading rows manually and use Data > Group instead.
How do I remove an outline completely?
Go to Data > Ungroup > Clear Outline. This removes the grouping and buttons but leaves all your data untouched.
Does outlining hide my data?
Only visually. Collapsed rows are hidden until you expand the group; nothing is deleted and nothing changes in formulas or printing unless you choose to print the collapsed view.
Is Auto Outline the same as a pivot table?
No. Auto Outline just adds collapse/expand controls to existing rows. A pivot table builds a new summary from raw data and has its own expand/collapse fields.