How to Add a Filter to a Pivot Table Grand Total
In this article
You cannot filter the Grand Total row or column directly, because Excel calculates it from the whole source range and ignores filters applied to the pivot field. What you can do is control which items feed the total: either apply a filter to a field (the grand total recalculates from the visible items only), or use a helper approach such as a calculated field, a second pivot table, or the GETPIVOTDATA function if you need the total to reflect a narrower slice than the pivot shows. The steps below are for Microsoft Excel on Windows, Mac and the web app; menu labels can differ slightly by version, device and region.
What You'll Need
- Excel 2016 or later, Microsoft 365, or Excel for the web, with your data already in a pivot table.
- A source range set up as a proper table: one header row, no blank rows or columns, no merged cells.
- At least one text or date field you can filter on (Region, Category, Month, Owner).
- Your data saved before you start. Changing source layout can require rebuilding the pivot, so keep a copy.
Step-by-Step
- Click any cell inside the pivot table. This makes the PivotTable Analyze and Design tabs appear on the ribbon. If they do not appear, you are probably clicking outside the pivot — click a value cell such as a grand total figure.
- Check where the field you want to filter sits. Open the PivotTable Fields pane (right-click the pivot and choose Show Field List, or use the Field List button on the Analyze tab). Look at the four areas: Filters, Columns, Rows, Values. A field in Rows or Columns can be filtered in place; a field in Values cannot.
- Add a report filter for a top-level cut. Drag the field you want to filter by — for example Region — into the Filters area of the Field List. A filter drop-down appears above the pivot. Open it, tick Select Multiple Items if you want more than one value, clear (All), then tick the values you want. Click OK. The grand total now recalculates using only the visible items.
- Filter a row or column field in place. Click the drop-down arrow on the row or column label inside the pivot (for example the arrow beside "Region" on the column header). Untick the items you do not want, or use Label Filters and Value Filters for conditions such as "greater than 5000" or "begins with North". Click OK.
- Confirm the total changed. Look at the Grand Total row and column. If they still show the full-source figures, a filter has not actually been applied — check that items are unticked in the drop-down rather than just greyed out by a slicer that is not connected to this pivot.
- Hide the grand total row or column instead, if you only want it out of the way. On the Design tab, open Grand Totals and choose Off for Rows and Columns, On for Rows Only, or On for Columns Only. This does not filter anything; it just removes the display.
- Use a slicer for a clickable filter. With a cell in the pivot selected, choose Insert Slicer on the Analyze tab (Insert > Slicer on the Insert tab in some versions) and tick the field. Click slicer buttons to filter; the grand total follows the selection. On the Slicer tab, use Report Connections if you have several pivots that should filter together.
- For a fixed slice the pivot does not show, build a second pivot or use a formula. Click a grand total cell once and type
=in another cell to see Excel generate a GETPIVOTDATA formula referencing that total. You can edit the arguments to point at a specific item instead of the grand total — for example pulling the total for one region while the pivot itself stays unfiltered. Alternatively, copy the source range to a new sheet, filter it there, and build a small pivot on the filtered copy for the total you need. - Save and, if the pivot is shared, refresh. Right-click the pivot and choose Refresh so any source changes are picked up along with your filters.
Common Mistakes
- Expecting a filter to remove the grand total. Filtering changes what the total sums; it does not hide the total row. Use Design > Grand Totals to hide it.
- Trying to filter the Values area. You cannot drop a filter on a field that only holds summed numbers. Move the field to Rows, Columns or Filters first, or use a Value Filter on a row field.
- Leaving stale items in the drop-down. Deleted categories can linger. Right-click the pivot, choose PivotTable Options, open the Data tab and set the number of items to retain per field to None, then refresh.
- Filtering a slicer that is not connected. A slicer left over from another pivot will look like it is filtering while the total stays put. Check Report Connections on the Slicer tab.
- Assuming the web app matches the desktop. Excel for the web supports slicers, report filters and grand total settings, but some advanced filter options and calculated items are only in the desktop app. Open the file in desktop Excel if a control seems missing.
- Filtering the source table and expecting the pivot to follow automatically. Hiding rows in the source does not affect the pivot unless the pivot is based on a table that you filter and refresh in the right order; filtering the pivot itself is the reliable route.
Tips
- Name the pivot's source as an Excel Table (Ctrl+T or Insert > Table) so new rows are included when you refresh, and your filters keep working on the expanded range.
- Use Label Filters and Value Filters (Top 10, Above Average) on a row field when you want a moving filter that updates after each refresh rather than a fixed tick-list.
- If you need both an all-items total and a filtered total side by side, put two pivots on one sheet: one unfiltered, one filtered by a slicer that is deliberately not connected to the first.
- Keep filter fields out of the Values area so they stay visible in the Field List drop-downs.
- Print or export only the filtered view: filters carry into PDF and print output, so check the page before sending.
Troubleshooting
The grand total ignores my filter. Confirm the filter is applied inside the pivot, not on the source range. Then right-click the pivot and choose Refresh. If the pivot is built from a data model with multiple tables, filters on related tables can behave differently — check the relationships in the Data Model.
The filter drop-down is missing. The field is probably in Values, or the pivot style has hidden field headers. On the Design tab, check whether Field Headers is switched on, and move the field to Rows or Filters.
Grand totals show wrong numbers after filtering. A calculated field may be summing across all items rather than the visible ones, depending on how the formula is written. Rebuild the calculation as a measure, or use a filtered copy of the source.
If that did not work: save a copy of the workbook, then rebuild the pivot from a clean source range (no blanks, no merged cells). If the file still misbehaves, close and reopen Excel, and check that the workbook is not in a compatibility mode that limits pivot features.
Frequently Asked Questions
Can I filter just the grand total and keep everything else?
Not directly. The grand total is calculated, not a filterable field. Filter one of the fields feeding it, hide the total with Design > Grand Totals, or build a second pivot for the narrower figure.
Why does the grand total not match the visible rows?
Usually a refresh issue or a filter applied to the source rather than the pivot. Refresh the pivot, then reapply the filter from the pivot's own drop-down.
Do slicer selections change the grand total?
Yes, provided the slicer is connected to that pivot. Check Report Connections on the Slicer tab if the total does not move.
Can I save a pivot with its filter applied?
Yes. Filters are stored with the workbook and reappear when you reopen it, though they may reset if the source range changes enough to drop the filtered items.