In Excel for Microsoft 365 on Windows, select the rows or columns you want to group and press Alt+Shift+Right Arrow. To remove the group, select it and press Alt+Shift+Left Arrow. Grouping creates collapsible outline controls; it hides detail temporarily but does not delete the selected rows or columns.
The Excel shortcut and what it groups
The grouping shortcut applies to rows and columns, not to a collection of arbitrary cells as a way to combine or merge them. Select complete rows or columns when possible, then use the shortcut. Excel creates an outline level, shown by brackets beside row numbers or above column letters, with a small minus or plus control for hiding or showing the detail.
If you select cells inside a range rather than whole rows or columns, Excel may open a dialog asking whether the grouping direction is Rows or Columns. Choose the direction that matches the structure you want. If Excel selects a direction automatically, check the outline brackets afterward to confirm that it grouped the intended rows or columns.
For example, if rows 5 through 12 contain monthly transactions and row 13 contains their total, select rows 5 through 12 and press Alt+Shift+Right Arrow. The total remains visible while the transactions can be collapsed. This is often more useful than including the total in the group, because the summary stays on screen when the detail is hidden.
How to group rows or columns from the ribbon
The ribbon provides the same command if you prefer not to use a shortcut, or if the shortcut is intercepted by a keyboard layout or remote desktop. In Excel for Microsoft 365 on Windows, select the rows or columns, then choose Data > Outline > Group. If Excel asks, choose Rows or Columns and confirm.
- Click a row number or column letter to select an entire row or column. Drag across adjacent row numbers or column letters to select a range.
- For a cell selection, highlight the detail range and decide whether the outline should run across rows or columns.
- Choose Data > Outline > Group, or press Alt+Shift+Right Arrow.
- Look for the outline bracket and minus button, then click the minus button to collapse the detail.
- Click the resulting plus button to expand it again.
To undo the structure without changing the data, select the grouped rows or columns and use Data > Outline > Ungroup, or press Alt+Shift+Left Arrow. If you need to remove all outline levels on a sheet, use the drop-down beside Group or Ungroup and choose Clear Outline. Clearing an outline removes the grouping structure, not the worksheet contents.
Choosing rows or columns
Group rows when the detailed records are arranged vertically and you want to fold away blocks of records. Common examples include transactions under monthly totals, tasks under project headings, or line items beneath a department subtotal. Group columns when periods, scenarios, or supporting calculations run horizontally and you want to conceal some columns while retaining key totals.
Before grouping, consider which information should stay visible. A summary row or column placed outside the detail group remains on screen when the group is collapsed. This makes a useful report pattern: detail first, followed by a subtotal or summary that remains visible. If the summary is inside the group, it will disappear along with the detail, which may make the collapsed view less informative.
Excel can display summary rows above or below detail, and summary columns to the left or right. The outline settings are available from the small dialog launcher in the Data tab’s Outline group, under Settings. The option for summary rows or columns changes where Excel expects summaries when creating outlines; it does not move existing data. Review the setting and the visible bracket placement if a new group appears on an unexpected side.
Nested groups and outline levels
Groups can be nested to create more than one level of detail. For instance, a worksheet could group individual daily records under each week, then group several weeks under a month. The outer group can hide a larger block, while inner groups let a reader expand only the week or section they need.
Use the numbered outline buttons, usually shown above the row numbers or to the left of the column letters, to display a particular level. Level 1 generally shows the most summarized view; higher levels reveal progressively more detail. The exact visible content depends on how the groups and summary rows were arranged. The plus and minus controls expand or collapse one particular section, while the level buttons affect all groups at that level.
For a practical example, suppose rows 2–8 hold daily entries for Week 1, rows 9–15 hold Week 2, and row 16 contains a monthly total. You can group each week’s entries separately, leaving any weekly summary rows outside those groups. You can then group the weekly blocks together for a broader monthly outline. Build and test one level at a time: nested outlines are easier to understand when the bracket lines and summary placement are clear.
Grouping compared with hiding rows
Grouping and hiding both make rows or columns disappear from the normal view, but grouping adds an explicit outline structure. The plus and minus controls communicate that detail is available, and outline levels make it possible to switch among summarized views. Hiding rows manually does not create those controls or levels.
Use grouping when people will repeatedly switch between summary and detail, or when the worksheet is intended as a report. Use Hide when you only need to temporarily conceal a particular row or column and do not need an outline. Neither operation removes data. Also, grouping is not a security feature: a viewer who can access the workbook may expand the group or unhide rows. Do not use it to protect confidential information.
Common shortcut problems
If Alt+Shift+Right Arrow does nothing, first check that Excel has focus and that the selection is on a worksheet rather than in a cell-editing state. Press Esc or Enter to leave cell editing, select the rows or columns again, and retry. Keyboard remapping tools, remote desktop software, or a nonstandard keyboard can also intercept key combinations; use Data > Outline > Group to confirm whether the command itself works.
- The wrong direction is grouped: When a cell range is selected, Excel may ask Rows or Columns. Choose explicitly and inspect the bracket after grouping.
- The minus button is missing: Check whether outline symbols are displayed and whether the group was created. On Windows, Ctrl+8 toggles the display of outline symbols; it does not remove groups.
- The total disappears too: The summary row or column is likely inside the selected group. Ungroup the range and recreate it without including the summary.
- Some rows cannot be grouped: Check the selected range and any existing groups. Overlapping or poorly nested selections can make the outline difficult to manage; remove the unintended group and rebuild the structure in clear, adjacent sections.
- Worksheet protection blocks the command: Protected sheets may restrict outline changes. Review the sheet’s protection settings or ask the workbook owner to adjust them; do not assume the shortcut will override protection.
When brackets seem to have vanished, do not immediately repeat the shortcut: it could create another outline level. First use Ctrl+8 to check whether symbols are hidden, and inspect Data > Outline for the Ungroup and Clear Outline commands. Saving a copy before a substantial restructuring is sensible, especially in a shared report.
Windows, Mac, and Excel for the web
The Windows shortcut for grouping is Alt+Shift+Right Arrow; the corresponding ungroup shortcut is Alt+Shift+Left Arrow. In Excel for Mac, the equivalent key is usually Option+Shift+Right Arrow to group and Option+Shift+Left Arrow to ungroup. Mac keyboard settings, keyboard layouts, and Excel versions can affect shortcut behavior, so the ribbon route is a reliable fallback: select the range and use Data > Group or Data > Ungroup.
In Excel for the web, use the Data tab’s grouping controls if the desktop shortcut does not work in your browser. Browser shortcuts and operating-system settings can compete with Excel’s key combinations. The core idea is the same: select the range, group it, then use the outline controls to show or hide detail. If a workbook is opened in a different Excel version, confirm that its outline controls are visible and usable there before distributing it.
Good practices for readable outlines
A useful outline is planned around how someone will read the sheet, not just around which rows can be hidden. Keep related detail together, make summary labels clear, and avoid leaving blank rows in the middle of a group unless they serve a deliberate layout purpose. Clear section labels and totals help readers understand what the collapsed view represents.
- Group one logical block at a time, such as a month’s transactions or a project’s task rows.
- Keep totals outside detail groups if they should remain visible in the collapsed view.
- Use nested levels only when they reflect meaningful layers, such as days within weeks and weeks within months.
- Test both the collapsed and expanded views, including the numbered outline-level buttons.
- Tell collaborators that the plus and minus controls reveal existing data rather than changing or deleting it.
Grouping does not calculate subtotals automatically. It only organizes visibility. If a report needs totals, add appropriate formulas or use Excel’s Subtotal feature separately, and make sure the chosen summary rows are placed where the outline can leave them visible. Keeping calculation and display structure distinct makes a workbook easier to audit.
Frequently Asked Questions
What is the keyboard shortcut to group rows in Excel?
On Windows, select the rows and press Alt+Shift+Right Arrow. On Mac, use Option+Shift+Right Arrow if that combination is available; otherwise use Data > Group.
What is the shortcut to ungroup rows in Excel?
On Windows, select the grouped rows and press Alt+Shift+Left Arrow. On Mac, the equivalent is usually Option+Shift+Left Arrow. You can also choose Data > Ungroup.
Can I group columns with the same shortcut?
Yes. Select the columns you want to group and use the same grouping shortcut. If you selected cells rather than full columns and Excel asks for a direction, choose Columns.
Does grouping delete or change my data?
No. Grouping adds an outline that lets you hide and reveal rows or columns. The underlying values and formulas remain in the worksheet, and collapsing a group does not delete its contents.
Why can’t I see the plus and minus buttons?
Outline symbols may be turned off, or the range may not be grouped. On Windows, press Ctrl+8 to toggle outline-symbol display. If symbols still do not appear, check the Data tab’s Outline commands and confirm that the group exists.
Can I group individual cells?
No. Excel’s outline grouping organizes rows or columns, rather than grouping isolated cells as a single movable object. Select complete rows or columns, or select a cell range and choose whether to create a row or column outline.
Related
- Excel Format as Number: Steps and Common Fixes
- Excel Format by Number Range with Conditional Formatting
- Excel Find and Delete Text: Replace, Clear, or Remove
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Google Sheets Date Format Not Applying? Fixes That WorkIf a date format in Google Sheets is not applying, the cells often contain text rather than real…
- IF Rules in Google Sheets: How Formulas and Rules WorkIn Google Sheets, an IF rule is a formula that checks a condition and returns one result when…
- How to Archive Older Emails in Outlook Without Losing ThemTo archive older emails in Outlook, select the messages and choose Archive to move them out of your…
- Excel Date Showing as Hashtags? Causes and Fixes ExplainedIf an Excel date appears as hashtags (such as #######), the cell usually is not wide enough to…
- XLOOKUP in Google Sheets: How It WorksYes—Google Sheets has a built-in XLOOKUP function, so you can search a row or column and return a…
- Can You Change Border Color in Excel? Steps and TipsYes. In Excel for Microsoft 365 on Windows, select the cells, go to Home > Font > Borders…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.