How to Group Columns in Excel: Shortcuts, Outline, and Nested Groups
Group columns in Excel with one shortcut. Collapse, expand, nest up to 8 levels, and ungroup without losing data. Step-by-step with quirks fixed. ⏳

To group columns in Excel, select the column letters and press Alt + Shift + Right Arrow, or go to Data > Outline > Group. Excel adds an outline bracket with a minus button, so you can collapse and expand the columns without deleting anything.
Spreadsheets get unwieldy fast. You build a model with twenty columns of monthly figures, three columns of formulas, and another batch of helper columns nobody else needs to see, and within a week the sheet feels like a wall of numbers. Grouping columns in Excel solves this. Instead of deleting work or hiding columns one by one, you collapse whole sections behind a tidy plus or minus button—then expand them when you need them back.
This is not a flashy feature. It does not appear in marketing screenshots. But once you start using it, every report you build looks cleaner, every meeting moves faster, and every audit trail stays intact. The columns are still there. The formulas still calculate. You just hide the detail until somebody asks for it.
You will learn three ways to group columns: the keyboard shortcut, the ribbon route, and the auto-outline. We'll cover nested groups (groups inside groups), how to remove them without losing data, and the small handful of quirks that trip people up the first time they try it.
If Excel is something you work with daily, the Excel cheat sheet is worth bookmarking alongside this guide.
What grouping columns actually does
Grouping is Excel's built-in outline tool. When you select a range of columns and group them, Excel draws a thin bracket above the column letters with a minus sign on the right edge. Click the minus and those columns collapse into a single hidden block. Click the plus that replaces it and they reappear. Nothing is deleted. Nothing is moved.
That last point matters. Hiding columns the old-fashioned way (right-click, Hide) gives you the same visual result, but it leaves no marker. Three months later, somebody opens the file, sees column G jump to column M, and wonders what happened to H through L. Groups leave a tell—the little outline bar at the top of the worksheet—so anyone can see at a glance that hidden data exists and how to expand it.
Groups also support nesting. Microsoft documents outlines of up to eight levels. Grouping rows works the same way (see how to group rows in Excel). That sounds excessive until you build a multi-year P&L where each quarter is a group, each year is a group of quarters, and the whole report rolls up under a single grand-total group.
Why Group Columns in Excel

Method 1: The keyboard shortcut (fastest)
Select the column letters you want to group—click the letter at the top, hold Shift, click the letter at the other end of the range. Then press Alt + Shift + Right Arrow on Windows, or Command + Shift + K on Mac (Mac shortcut not re-verified against Microsoft's shortcut list; the ribbon route below works on both). Excel adds the outline bracket above the columns and the minus button to its right.
To ungroup, select the same range and press Alt + Shift + Left Arrow (Windows) or Command + Shift + J (Mac). The outline disappears, but the columns themselves remain.
This shortcut also works on rows—just select rows instead of columns. The keystroke is identical. If you forget which arrow direction is "group" and which is "ungroup," remember that Right is forward (adding structure) and Left is back (removing it).
What if the shortcut does not respond?
Two things usually cause the keystroke to fail. First, you have not selected entire columns—you selected a cell range instead. In that case, Excel pops up a dialog asking whether to group by Rows or Columns. Pick Columns and press Enter. Second, the worksheet is protected. Unprotect it (Review tab, Unprotect Sheet) and try again.
Method 2: The ribbon route (most discoverable)
If you cannot remember the shortcut, the ribbon path is fine. Select your columns, go to the Data tab, find the Outline group on the far right, click Group, then click Group again from the dropdown. If you select entire columns, Excel groups them immediately; if you select only cells, a dialog asks whether to group Rows or Columns. The same outline appears.
The Outline section on the Data tab has a few related buttons worth knowing. Group creates the group. Ungroup removes it. Subtotal inserts subtotal rows and groups them automatically. And the small launcher arrow in the corner opens the Settings dialog where you can control whether summary rows appear above or below the detail, and whether summary columns appear to the left or right.
That last setting trips people up. By default, Excel assumes summary columns sit to the right of detail columns. The minus button therefore appears at the right edge of the group. If your totals sit on the left—which is common for budget templates where the YTD column comes first—you want to flip the setting so the button appears on the left side instead.
The Quickest Path
Select the column letters at the top of the sheet, then press Alt + Shift + Right Arrow on Windows or Command + Shift + K on Mac. The outline bracket appears above the columns with a minus button on the right.
Click the minus to collapse, the plus to expand. To ungroup, press Alt + Shift + Left Arrow on Windows or Command + Shift + J on Mac. The outline disappears, but no columns are deleted.
Three Ways to Group Columns
Fastest method once it's in your muscle memory. Press Alt + Shift + Right Arrow on Windows or Command + Shift + K on Mac after selecting the columns. Same keystroke works for rows.
- ▸Windows: Alt + Shift + Right Arrow
- ▸Mac: Command + Shift + K
- ▸Ungroup: Alt + Shift + Left Arrow
More discoverable for occasional users. Go to the Data tab, find Outline on the far right, click Group, then choose Group again. Easier to teach than the keyboard shortcut.
- ▸Data tab on the ribbon
- ▸Outline section, far right
- ▸Group dropdown then Group
Excel builds groups from your summary-column formulas automatically. Works when each summary column references the detail columns it totals.
- ▸Data > Outline > Group > Auto Outline
- ▸Needs summary formulas referencing detail cells
- ▸Clear with Ungroup > Clear Outline
Nest groups to build multi-level outlines of up to eight levels. Level buttons appear in the top-left of the outline area.
- ▸Up to 8 outline levels
- ▸Level buttons top-left
- ▸Do not include the summary column
Method 3: Auto-outline (when the structure is obvious)
If your worksheet already has summary columns with formulas, Excel can detect the pattern and group everything for you. Click a cell in the range, go to Data > Outline > Group > Auto Outline. Microsoft notes that outlining by columns requires summary columns whose formulas reference the detail columns for each group.
If Auto Outline appears to do nothing, check that the summary columns really contain formulas that reference the detail cells and that the range has no blank rows or columns. Also check the direction setting: if your totals sit to the left of the detail, open the Outline Settings dialog (Data > Outline, small launcher arrow) and clear Summary columns to right of detail.
To remove an outline, go to Data > Outline > Ungroup > Clear Outline. This strips every group on the sheet at once.
Working with nested groups
You can build an outline of up to eight levels. Select the detail columns for an inner group (not the summary column next to them), then choose Data > Outline > Group. Each nested level adds a higher number to the level buttons in the top-left corner of the outline area.
Level button 1 shows only the highest summary level, and each higher number reveals more detail. The highest number shows everything. If an outline has three levels, button 3 expands all of it and button 1 hides all the detail.
Nested groups keep serious financial models readable. Take a budget with twelve months across the top: group the three months inside each quarter, then group the quarters (with their quarter totals) under the year. Press 1 for the annual view or 2 for quarterly numbers.
Microsoft's own walkthrough selects the outer group first and then the inner groups, but the key rule is the same either way: never include the summary column in the detail group you are creating, and keep all data displayed (not collapsed) while you group so you do not select the wrong columns.

Shortcuts by Platform
Group columns: Alt + Shift + Right Arrow
Ungroup columns: Alt + Shift + Left Arrow
Show outline levels: Click the 1, 2, 3 buttons in the top-left of the outline area. Alt + Shift + = shows and Alt + Shift + - hides the detail of the selected group.
Hide outline symbols: Ctrl + 8 toggles the entire outline display on and off. Useful when printing a sheet that has groups you'd rather not show in the output.
Hiding versus grouping: when to use which
Both hide columns from view. The difference is intent. Hide is a one-off—you do not want a column visible right now, and you may forget you hid it. Group is a system—you want a reusable view that anyone can expand without having to scan the column letters for gaps.
For workbooks shared with other people, groups are almost always the better choice. The outline bracket signals "there is more here" in a way that hidden columns do not.
There are still moments when Hide makes sense. If you are stripping a sheet for an external client and you genuinely do not want them to notice the missing columns, Hide blends in better than a group bracket. If you have just two helper columns next to your data, the overhead of building a group feels like too much for too little.
Expanding and collapsing without clicking each group
The plus and minus buttons let you toggle one group at a time. The level buttons (the small 1, 2, 3 in the top corner of the outline area) toggle every group at that level simultaneously. Press 1 to collapse all top-level groups. Press the highest number you see to expand everything fully (Microsoft: select the lowest level to show all detail, level 1 to hide all of it). This is the quickest way to switch a large model between summary view and detail view.
On Windows you can also click the plus or minus button on the outline bar, or press Alt + Shift + = to show the detail of the selected group and Alt + Shift + - to hide it, as Microsoft documents.
One quirk: if you save a workbook with groups collapsed, the next person who opens it sees them collapsed too. That is usually what you want. But occasionally you save in the wrong state and somebody opens the file thinking columns are missing. Get into the habit of expanding everything (press the highest level number) before you save and ship a file, unless you have a deliberate reason not to.
Group vs Hide vs Auto Outline vs Subtotal: Quick Comparison
These four Excel tools all change what is visible, but they differ in whether they leave a marker, build levels, or add formulas.
| Tool | What it does | Where to find it | Leaves a visible marker? |
|---|---|---|---|
| Group | Collapses selected columns or rows behind a plus/minus button; up to 8 outline levels | Data > Outline > Group, or Alt + Shift + Right Arrow (Windows) | Yes, outline bracket and level buttons |
| Hide | Hides the selected columns or rows with no outline | Right-click the column letters > Hide | No, only a skipped column letter or row number |
| Auto Outline | Builds groups for you from summary formulas that reference the detail cells | Data > Outline > Group > Auto Outline | Yes, outline bracket and level buttons |
| Subtotal | Inserts SUBTOTAL formulas for each group of detail rows and creates the outline automatically | Data > Outline > Subtotal | Yes, outline bracket and level buttons |
| Clear Outline | Removes every group on the sheet; columns that were collapsed can stay hidden until you unhide them | Data > Outline > Ungroup > Clear Outline | No, the outline is removed |
If you ungroup or clear an outline while the detail columns are collapsed, the columns can stay hidden. Drag across the visible column letters on either side, then choose Home > Cells > Format > Hide & Unhide > Unhide Columns.
Expand the outline first (select the highest level button) before ungrouping and nothing stays hidden.
Removing groups without losing data
Ungrouping never deletes columns. It only removes the outline. Select the columns inside the group and press Alt + Shift + Left Arrow (Windows), or use Data > Outline > Ungroup. If the columns inside were collapsed when you ungrouped, they remain hidden afterwards—you'll need to select the surrounding columns, right-click, and Unhide.
This is the single most common point of confusion: people ungroup, the bracket disappears, the columns stay hidden, and they think the data is gone. It is not. Right-click and unhide, and it returns.
To strip every group from the worksheet in one shot, click anywhere in the data and choose Data > Outline > Ungroup > Clear Outline. This wipes the outline but, again, does not unhide any collapsed columns. Run an unhide pass afterwards if you need everything visible.
Common errors and how to fix them
The most frequent issue is ungrouping while the columns are collapsed. Microsoft notes that the detail columns can remain hidden afterwards, so drag across the visible column letters on either side, then go to Home > Cells > Format > Hide & Unhide > Unhide Columns.
Another classic: the group works on the active sheet but vanishes when you switch tabs. Groups are scoped to the worksheet, not the workbook. If you want the same outline on a duplicate sheet, copy the sheet (right-click the tab, Move or Copy, tick Create a Copy). Excel duplicates the groups along with everything else.
If you press the shortcut and Excel prompts "Group by Rows or Columns?" every time, it means you have not selected entire columns. Click the column letters, not the cells. The dialog goes away.

Group Columns the Right Way
- ✓Select entire column letters at the top of the sheet, not a cell range, before triggering the shortcut
- ✓Use Alt + Shift + Right Arrow on Windows or Command + Shift + K on Mac to group
- ✓Open Outline Settings to choose whether summary columns sit to the left or right of detail
- ✓Do not include the summary column in the detail group you are creating
- ✓Expand all levels (highest level button) before ungrouping or saving a shared file
- ✓Use Data > Outline > Ungroup > Clear Outline to strip every group on the sheet at once
- ✓Remember that ungrouping collapsed columns can leave them hidden; unhide them manually
- ✓Use Alt + Shift + = and Alt + Shift + - to show or hide detail of the selected group (Windows)
When grouping is the wrong tool
Grouping is great for hiding and revealing columns at speed. It is not a substitute for filtering, pivoting, or building a proper dashboard. If your real problem is "I have too much data and I only want to see relevant rows," AutoFilter or a slicer beats grouping every time.
If your real problem is "I want different stakeholders to see different slices of the same model," consider building separate report tabs that pull from one master data sheet—each report shows only what its audience cares about, no outline required.
Grouping shines when the column structure is fundamentally good and you just want to toggle detail on and off. The moment you find yourself wanting to reorder, recompute, or selectively show rows instead of columns, reach for a different tool.
For more visual organisation patterns, see freeze rows in Excel.
Practice: build a grouped quarterly report
Open a new workbook. In row 1, type Jan, Feb, Mar, Q1 Total, Apr, May, Jun, Q2 Total, Jul, Aug, Sep, Q3 Total, Oct, Nov, Dec, Q4 Total, Year in columns A to Q. In row 2, enter a number for each month. Put =SUM(A2:C2) in D2, =SUM(E2:G2) in H2, =SUM(I2:K2) in L2 and =SUM(M2:O2) in P2. Put =D2+H2+L2+P2 in Q2 for the year.
Now group A:C, E:G, I:K and M:O (the months of each quarter). Then select A:P (all months and quarter totals, but not the Year column) and group again. You now have three levels, so three level buttons appear. Press 1 and only the Year column remains. Press 2 and you see the four quarter totals plus the year. Press 3 and every month is visible.
The point of this practice run is muscle memory. Once your fingers know the shortcut, you stop hiding columns manually, and your workbooks become easier for colleagues to read and audit.
Grouping vs Hiding Columns
- +Outline bracket signals that hidden data exists, so other users notice the columns are collapsed rather than missing
- +One-click toggle between collapsed and expanded view, with a clear plus or minus button on the outline bar
- +Supports nesting up to eight levels deep for multi-tier financial models and complex reports
- +Level buttons collapse or expand every group at the same level in a single click
- +Formulas keep calculating inside collapsed groups — no impact on totals, subtotals, or downstream references
- −The outline bar takes up a thin strip at the top of the sheet, slightly reducing visible row space
- −Ungrouping leaves the columns hidden if they were collapsed at the time — manual unhide required afterwards
- −Excel allows grouping only on unprotected sheets, so protected templates need unprotecting first
Sample Excel Practice Questions
Try these questions from our free Excel practice tests. The correct answer and an explanation follow each question.
What is the maximum number of columns in a single Excel worksheet?
- A. 16,384
- B. 1,024
- C. 32,768
- D. 256
Answer: A. 16,384
Since Excel 2007, worksheets support 16,384 columns (2^14), labeled A through XFD.
When you sort a table by a column in Excel, what happens to the other columns in the same row?
- A. They move together with the sorted column to keep each row's data intact
- B. They remain in their original position
- C. They are sorted alphabetically as well
- D. They are hidden until the sort is cleared
Answer: A. They move together with the sorted column to keep each row's data intact
Excel sorts entire rows together, so related data in each row stays aligned regardless of which column is sorted.
Which Excel feature allows you to split a single column of data into multiple columns based on a delimiter?
- A. Flash Fill
- B. Text to Columns
- C. Power Query Split
- D. Data Separation
Answer: B. Text to Columns
Text to Columns (under the Data tab) splits cell content into separate columns using a delimiter like a comma or space.
Which Power Query transformation converts multiple columns such as Jan, Feb, and Mar into two columns named Attribute and Value?
- A. Pivot Column
- B. Group By
- C. Unpivot Columns
- D. Split Column
Answer: C. Unpivot Columns
Unpivot turns wide crosstab data into a tall, normalized list.
Excel Questions and Answers
About the Author

Business Consultant & Professional Certification Advisor
Wharton School, University of PennsylvaniaKatherine Lee earned her MBA from the Wharton School at the University of Pennsylvania and holds CPA, PHR, and PMP certifications. With a background spanning corporate finance, human resources, and project management, she has coached professionals preparing for CPA, CMA, PHR/SPHR, PMP, and financial services licensing exams.