Slicers in Excel: Filter Tables and PivotTables With Buttons

A slicer is a panel of buttons that filters an Excel Table or PivotTable with one click, and always shows what's filtered. One slicer can also control several PivotTables at once, which makes simple dashboards easy.

Excel TableTable Design → Insert Slicer
PivotTablePivotTable Analyze → Insert Slicer
Multi-selectCtrl + click

Add a slicer to an Excel Table

The table SalesData holds chocolate sales by product, region and sales rep in Kochi.

Sales data in an Excel Table
  1. Click in the table → Table Design → Insert Slicer.
  2. Tick the columns to filter by, here Product, Region and SalesRep, and click OK.
Insert Slicer on the Table Design tab
Insert Slicers dialog
Three slicers next to the table

Use a slicer

To Do this
Show one item Click its button
Show several items Ctrl + click, or turn on Multi-Select (the tick-list icon) and click
Clear the filter Click the funnel-with-cross icon at the top right, or Alt + C when the slicer is selected
Remove the slicer Select it and press Delete
Two products selected in a slicer
Filtering by product and region together

Faded buttons are items that are filtered out. Items with no data left show at the end in a lighter colour.

Format a slicer

On the Slicer tab, pick a style, set the number of Columns of buttons, and change the button height and width. Slicer Settings lets you hide items with no data and change the sort order.

Slicer styles
Slicer buttons arranged in several columns

Add a slicer to a PivotTable

Click the PivotTable → PivotTable Analyze → Insert Slicer, tick the fields, OK.

PivotTable of sales by city
Insert Slicer on the PivotTable Analyze tab
Slicers filtering a PivotTable

One slicer for several PivotTables

Right-click the slicer → Report Connections, tick each PivotTable it should control, and click OK. The PivotTables must come from the same source data.

Report Connections on the slicer menu
Report Connections dialog
One slicer filtering two PivotTables

Timeline: a slicer for dates

For a date field in a PivotTable, PivotTable Analyze → Insert Timeline gives a slider to pick days, months, quarters or years.

Things to know

  • Slicers work in Excel 2013 and later for Tables, 2010 and later for PivotTables, and in Excel for the web.
  • Formulas like SUM still add hidden rows. Use =SUBTOTAL(109,Sales[Amount]) to total only what the slicer shows.
  • When you protect the sheet, tick Use PivotTable & PivotChart and unlock the slicers so they still work.

Related