Excel Shortcut to Collapse a Group

How-to basics · Updated November 20, 2026

In Excel for Microsoft 365 on Windows, select a cell in the grouped detail rows or columns, then press Alt+Shift+- (Alt+Shift+minus) to collapse that outline group. To expand it again, press Alt+Shift+=; you can also click the minus or plus button beside the group.

What the Collapse Shortcut Does

Excel’s grouping feature creates an outline: detail rows or columns can be hidden temporarily while summary rows or columns remain visible. Collapsing a group hides its detail; it does not delete data, clear formulas, or change the underlying values. The hidden rows or columns are still part of the worksheet and can be shown again.

The Windows shortcut Alt+Shift+- is Excel’s Hide Detail command. The matching Show Detail command is Alt+Shift+=. The second shortcut uses the equals key, which is normally typed with Shift on a standard keyboard; Excel’s shortcut notation already includes Shift. Keyboard layouts vary, so if the key combination is awkward on yours, use the outline button or the ribbon command instead.

These shortcuts apply to an existing outline group. They are not the same as hiding a selected row or column with Ctrl+9 or Ctrl+0, and they do not create a group. If the rows have not been grouped, there is no outline group for Hide Detail to collapse.

Collapse One Group or Several

To collapse just one group, click a cell within the group’s detail area and press Alt+Shift+-. For example, if rows 5 through 12 contain monthly transactions and row 13 contains a total, click a cell in rows 5 through 12 before using the shortcut. Excel hides the grouped detail and leaves the associated summary visible, provided the outline is set up with a summary row.

If a worksheet contains several outline levels, the selected cell matters. A cell in a nested group operates on the relevant detail at that level; it does not necessarily collapse every group on the sheet. To collapse many groups at once, use the numbered outline level buttons that appear at the upper-left of the worksheet, above the row numbers and to the left of the column letters. Selecting a level displays that level of summary and hides detail below it.

For instance, a worksheet grouped first by month and then by transaction could have three outline levels. Clicking level 1 may show only the grand total, while clicking level 2 can show monthly totals and hide each month’s transactions. The precise display depends on how the outline was created and which summary rows or columns are included.

How to Group Rows Before Collapsing

If the shortcut does nothing, check whether the rows or columns are actually grouped. To create a row group in Excel for Microsoft 365 on Windows:

  1. Select the detail rows by clicking and dragging over their row numbers. To group columns, select their column letters instead.
  2. Open Data > Outline > Group. If Excel asks whether to group rows or columns, choose the appropriate option.
  3. Look for the outline bracket and a minus button beside the grouped rows, or above the grouped columns.
  4. With a cell in the detail selected, press Alt+Shift+-, or click the minus button to collapse the group.

You can also create a group with the Windows shortcut Alt+Shift+Right Arrow after selecting the rows or columns. To remove a group, select its rows or columns and use Data > Outline > Ungroup, or press Alt+Shift+Left Arrow. Ungrouping removes the outline structure; it is different from expanding a group, which simply makes the hidden detail visible again.

Use the Outline Buttons and Ribbon

The minus and plus controls are often the quickest alternative to a keyboard shortcut. Click the minus button next to a row group to collapse it; click the plus button in the same spot to expand it. For column groups, the controls appear above the column headings. These controls are useful when you want to change a particular group but are unsure which cell Excel will treat as the active group.

Excel also provides ribbon commands. Select a cell in the group, then choose Data > Outline > Hide Detail to collapse it. Choose Data > Outline > Show Detail to expand it. The commands may be unavailable or disabled if the selection is outside a grouped area. Ribbon layout can vary slightly with window width, but the commands are on the Data tab in the Outline section.

The small numbered outline buttons are especially useful for reviewing a large report. They show a consistent level across the sheet, whereas clicking individual minus buttons collapses groups one at a time. If you need a particular subtotal visible while hiding lower-level detail, choose the outline level that corresponds to that subtotal rather than hiding groups individually.

Rows, Columns, and Summary Placement

Excel can group rows or columns. A row group is useful for transaction lines under a subtotal; a column group can hide supporting calculations while leaving headline figures in view. The same Hide Detail and Show Detail shortcuts work with either type, as long as the active selection is in the appropriate outline.

By default, Excel commonly places row summary information below its detail and column summary information to the right. The outline’s direction affects what remains visible when detail is hidden. If a subtotal disappears along with the details, check where that subtotal sits and whether the outline settings match the worksheet’s layout. In the Data tab’s Outline section, open the Outline Settings dialog to review options such as whether summary rows appear below detail or summary columns to the right of detail.

Grouping is a view and organization feature, not a calculation. Excel does not automatically total grouped values simply because they are grouped. A subtotal or other summary formula must already be present, or you can use Excel’s Subtotal feature where it fits the data. Collapsing a group changes what is displayed, not the formula logic or the values being summarized.

Common Problems and Fixes

  • Nothing happens: Confirm that the active cell is inside grouped detail, rather than in an unrelated row or column. If there is no outline bracket or plus/minus control, create a group first.
  • The wrong level collapses: In nested outlines, click a cell in the specific detail group you intend to change. For a whole-sheet view, use the numbered outline level buttons.
  • The outline symbols are missing: In Excel for Windows, check File > Options > Advanced, then the display options for the worksheet, and make sure Show outline symbols if an outline is applied is enabled. The worksheet must also have an outline.
  • Some rows stay visible: They may not belong to the selected group, or they may be summary rows. Check the outline brackets and group boundaries, and create or adjust groups as needed.
  • The shortcut types a character or behaves differently: Keyboard layout, operating system, and Excel version can affect key combinations. Try the Data tab’s Hide Detail command or the minus button to distinguish a shortcut issue from a grouping issue.

Also distinguish outline grouping from ordinary row hiding. Ctrl+9 hides selected rows, and Ctrl+Shift+9 unhides rows in Windows; Ctrl+0 hides selected columns. Those commands do not provide the same nested outline levels or the group’s plus/minus controls. If a row was hidden individually rather than grouped, use the relevant unhide command or the row headings’ context menu instead of expecting Alt+Shift+- to manage it.

Excel for Mac and Excel for the Web

The shortcut given above is for Excel for Microsoft 365 on Windows. Excel for Mac uses different modifier-key conventions, and available combinations can also depend on the keyboard and macOS settings. If you do not have a dependable shortcut on your Mac, select a cell in the group and use Data > Hide Detail or Data > Show Detail, or click the outline minus or plus control. The outline controls themselves work independently of memorizing a Windows key combination.

In Excel for the web, use the Data tab and the available outline controls to hide or show grouped detail. Keyboard shortcut support can differ from desktop Excel and may depend on the browser, so the ribbon command or the visible outline buttons are the safer route when the Windows shortcut does not work. In any version, collapsing an outline is reversible; it does not remove the data.

When to Use Grouping Instead of Hiding

Use grouping when you expect to switch repeatedly between detail and summary views, or when the worksheet has multiple meaningful levels such as years, months, and transactions. Outline level buttons make these views easier to revisit, and the group controls clearly indicate that detail is temporarily hidden.

Use ordinary hiding for a small one-off display change when you do not need hierarchical controls. Use a filter when the goal is to show only records that meet conditions, such as transactions for one region. Filters hide records according to criteria; grouping hides sections of the sheet according to the outline structure. They solve different problems, and a filtered list is not the same thing as a collapsed group.

Frequently Asked Questions

What is the shortcut to collapse a group in Excel?
In Excel for Microsoft 365 on Windows, select a cell in the grouped detail and press Alt+Shift+-. This runs Hide Detail for the outline group.

How do I expand a collapsed group?
Select a cell in the group and press Alt+Shift+=, or click its plus button. You can also choose Data > Outline > Show Detail.

Can I collapse all groups with one shortcut?
There is not a single standard Windows shortcut that collapses every outline group to a chosen level. Click an outline level number, such as 1 or 2, to display that level across the worksheet.

Why can’t I see the plus and minus buttons?
The sheet may not contain an outline, or outline symbols may be hidden in Excel’s display options. Check that rows or columns are grouped and that the worksheet is set to show outline symbols.

Does collapsing a group delete or change its data?
No. It temporarily hides the grouped detail from view. Expanding the group reveals the same rows or columns again, and formulas continue to refer to the underlying cells.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.