The keyboard shortcut for the Excel Subtotal feature is Alt + Shift + Right Arrow on Windows: it inserts the SUBTOTAL function for the cells you have currently selected, but only when the cells above or to the left of your selection contain values. On a Mac, the shortcut is Command + Shift + T. If you simply want to add up a range the way a calculator would, that is plain Alt + = (AutoSum), which inserts SUM. The two are not the same: AutoSum ignores nothing, while SUBTOTAL can skip rows that a filter or an outline group has hidden. That difference is the whole reason this shortcut matters, so the steps below cover both, plus the built-in Subtotal command that inserts visible subtotals grouped by a column.
One note before you start: menu labels and shortcut behaviour differ slightly between Excel versions, between Windows and Mac, and between the desktop app and Excel for the web. The desktop Windows and Mac apps support the shortcuts below; Excel for the web supports AutoSum from the ribbon but not every keystroke.
What You'll Need
- Excel for Windows or Excel for Mac, ideally a desktop installation rather than the web version.
- A table or list with a header row and numeric columns, and no completely blank rows or columns inside it. Blank gaps confuse AutoSum and the Subtotal command when they work out what to include.
- If you plan to use the Subtotal command: the column you want to group by should contain repeated values (a category, a region, a month) and should ideally be sorted so those values sit together.
- Optionally, a filtered table, if you want to see the filtered-only total in action.
Step-by-Step
Option A: Insert SUBTOTAL with the keyboard
- Click into the first cell just below (or to the right of) the numbers you want to total.
- Hold Alt and Shift together and press the Right Arrow key. Excel inserts a formula that starts with
=SUBTOTAL(. - Excel usually proposes function number 109, which is SUM that ignores hidden rows. If you want a different calculation, type the function number instead of accepting the default: 101 for AVERAGE, 102 for COUNT, 103 for COUNTA, 104 for MAX, 105 for MIN, 107 for STDEV, 109 for SUM. The 100-series numbers ignore hidden rows; the 1-series numbers (1 to 11) include them.
- Confirm the range Excel highlighted, then press Enter. Press Tab instead if you are filling across a row.
- Check the result against a simple manual total the first time, so you know hidden rows are being excluded as expected.
On a Mac, use Command + Shift + T in place of Alt + Shift + Right Arrow. If that key combination does nothing, open the Tools menu and look for the option to insert a function, or use the formula bar directly.
Option B: Insert AutoSum (SUM) with Alt + =
- Select the empty cell below a column of numbers.
- Press Alt + = on Windows, or Command + Shift + T on Mac if your version maps AutoSum there.
- Excel highlights the range it believes you want. Drag to correct the range if it stopped early at a blank cell.
- Press Enter.
Remember that the total produced this way includes hidden rows. If you filter the list afterwards, the AutoSum total will not change, which is often mistaken for a bug.
Option C: Use the Subtotal command to build grouped subtotals
- Sort your data by the column you want to group on, using Data > Sort. Grouping only produces tidy results when the same values are adjacent.
- Select any cell inside the data range.
- Go to the Data tab and click Subtotal in the Outline group.
- In the dialog, choose the column to group by under At each change in.
- Choose the function (Sum, Count, Average and so on) under Use function.
- Tick the numeric columns you want subtotalled under Add subtotal to.
- Click OK. Excel inserts SUBTOTAL rows after each group and a grand total at the bottom, and adds outline buttons numbered 1, 2 and 3 at the left edge of the sheet.
- Use the outline buttons to collapse to level 2 and see only the group subtotals, or level 1 for the grand total.
To remove the result later, reopen Data > Subtotal and click Remove All.
Common Mistakes
- Using SUM instead of SUBTOTAL. If you plan to filter the list and expect the total to follow the filter, SUM will not do it. Use SUBTOTAL with a 100-series function number.
- Picking a 1-series function number. SUBTOTAL(9, range) still ignores rows hidden by a filter but includes rows hidden manually. SUBTOTAL(109, range) ignores filtered rows but also honours manual hiding. Knowing which number you used explains most surprising results.
- Nesting SUBTOTAL inside itself. If you subtotal a column that already contains SUBTOTAL formulas, Excel deliberately skips those nested SUBTOTAL cells to avoid double counting. Users who expect the totals to be added in get a smaller number and assume the formula is broken.
- Forgetting to sort first. The Subtotal command groups consecutive identical values, so a single category split into two blocks produces two subtotals for it.
- Totalling past a blank row. AutoSum stops at the first blank cell; extend the highlighted range manually if the data continues further down.
- Mixing text into a numeric column. Numbers stored as text are silently ignored by SUM and SUBTOTAL, so the total looks low with no error shown.
Tips
- Press the outline level button 2 before copying a summary; that view gives you just subtotals plus the grand total.
- Format your source data as a table with Ctrl + T. A table's Total Row recalculates only for visible rows when you filter, which is a robust alternative to SUBTOTAL formulas.
- Use SUBTOTAL(3, range) as a quick count of visible rows to confirm a filter is doing what you think.
- Keep a grand total on its own row below a blank separator so a later AutoSum does not accidentally include a subtotal row.
- If you use filters heavily, the numbered outline plus SUBTOTAL is usually cleaner than one formula per visible region.
Troubleshooting
The shortcut does nothing
Click a single cell first; the shortcut needs an active cell within or just outside the data. On some laptops, the function key row is set to media controls by default, so try Fn + Alt + Shift + Right Arrow, or check the manufacturer's key setting. Keyboard layouts and add-ins can also intercept Alt combinations, so test in a blank workbook to narrow it down.
The formula appears but the total is wrong
Click the cell containing the total and check the range in the formula bar. Wrong range is the usual culprit. Then check for numbers stored as text: select the column, look at the status bar, or use the warning icon that appears beside such cells to convert them.
The total does not change when I filter
The formula is probably SUM or a SUBTOTAL with a 1-series function number. Replace it with SUBTOTAL(109, range) for a sum, or SUBTOTAL(101, range) for an average over visible rows only.
Subtotal rows appeared in an odd place
Reopen Data > Subtotal, click Remove All, sort properly, and run it again. Removing does not delete your data, only the inserted subtotal rows and outline.
If that did not work
Try a different approach: build the total with the formula bar directly, or convert the range to a table and use its total row. If the workbook misbehaves in general, save a copy, close Excel, reopen it, and test in a new file to confirm whether the problem is the workbook or the installation.
Frequently Asked Questions
What is the shortcut for SUBTOTAL in Excel?
On Windows, Alt + Shift + Right Arrow inserts the SUBTOTAL function for the selected range. On Mac, use Command + Shift + T. Many people actually mean AutoSum, which is Alt + = on Windows.
Does SUBTOTAL ignore hidden rows?
Yes, when you use the 100-series function numbers (101 to 111). Rows hidden by a filter are always excluded; rows hidden manually are excluded too under this series but included under the 1-series numbers.
Why does my SUBTOTAL give a smaller number than SUM?
Either rows are hidden or filtered out, or the range contains other SUBTOTAL cells, which are skipped by design to prevent double counting. Check the function number and the range first.
Can I use the shortcut on Excel for the web?
The web version supports AutoSum from the Home tab ribbon but not all desktop keystrokes. Use the ribbon button, or open the file in the desktop app for the full shortcut set.
How do I remove subtotals without deleting data?
Go to Data > Subtotal and click Remove All. This strips the inserted subtotal rows and outline levels while leaving your original records intact.