How to Fix Incorrect Traffic Light Colors After Using Excel Slicers
Question details
The user needs to fix an issue where traffic-light conditional formatting in a PivotTable displays incorrect colors after filtering data with slicers.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Filtering a PivotTable that has traffic-light conditional formatting applied using slicers.
- Observed behavior
- Traffic-light icons change to incorrect colors after slicer selections are made due to inconsistent percentage value storage.
Ensure your PivotTable data source is updated and note the exact cells where the traffic light conditional formatting is currently applied.
Change Conditional Formatting Rule from Percentage to Number
Modifying the rule type ensures Excel calculates and compares the decimal values correctly, regardless of slicer filtering.
Excel calculates and stores percentage values differently when using conditional formatting icon sets. When a slicer filters a PivotTable, the relative percentage thresholds recalculate based on the newly visible data, causing the colors to shift.
By using decimals and setting the rule type to 'Number' instead of 'Percent', the threshold values remain absolute and stable. This ensures the correct traffic light color is displayed even when the PivotTable is filtered.
Select the cells in your PivotTable containing the traffic light conditional formatting. Go to the 'Home' tab on the ribbon, click 'Conditional Formatting', and select 'Manage Rules'.
In the Rules Manager dialog box, select your traffic light icon set rule and click the 'Edit Rule' button.
In the rule description section, locate the 'Type' dropdown menus for both the green and yellow icons. Change these dropdowns from 'Percent' to 'Number'.
Enter your target threshold values as decimals in the 'Value' fields. For example, if your threshold was 80%, enter 0.8. If it was 50%, enter 0.5.
Click 'OK' to close the Edit Formatting Rule dialog, then click 'Apply' and 'OK' in the Rules Manager to save your changes.

Use WPS Spreadsheet for Stable Conditional Formatting
WPS Spreadsheet provides robust support for PivotTables, slicers, and complex conditional formatting. You can easily manage traffic light icon sets using number types to ensure accurate data visualization without unexpected color shifts.
- 1. Select PivotTable Data: Open your spreadsheet in WPS Office and highlight the PivotTable cells containing your traffic light icons.
- 2. Open Rule Manager: Navigate to the 'Home' tab, click on 'Conditional Formatting', and select 'Manage Rules'.
- 3. Update to Number Type: Edit your Icon Set rule, change the Type dropdown to 'Number', input your decimal thresholds, and apply the rule.

Frequently Asked Questions
Why does Excel change my conditional formatting colors when I use a slicer?
When a slicer filters a PivotTable, the grand totals and relative values change. If your conditional formatting is based on 'Percent', Excel recalculates the thresholds based on the newly visible data, which alters the icon colors. Using absolute 'Number' values prevents this recalculation.
How do I convert percentages to decimals for conditional formatting?
To convert a percentage to a decimal, divide the percentage number by 100. For example, 75% becomes 0.75, and 33% becomes 0.33. Enter these decimal values in the 'Value' field when the rule type is set to 'Number'.
Does this fix apply to other conditional formatting icon sets besides traffic lights?
Yes, this solution applies to all conditional formatting icon sets (like arrows, flags, shapes, or data bars) that rely on percentage-based thresholds in PivotTables.
Can I apply conditional formatting to the entire PivotTable column?
Yes, when creating or editing the rule, you can use the 'Apply Rule To' options at the top of the Edit Rule dialog box to apply the formatting to all cells showing the specific value field for the row and column intersections.




