How can Conditional Formatting be Applied to a Bar Chart in Power BI?

Conditional formatting in Power BI allows users to apply specific formatting rules to visualizations, such as bar charts, based on certain conditions or criteria. In a bar chart, this means that the color, font, size, or other visual properties of individual bars can be changed based on predetermined rules. For example, bars with values above a certain threshold can be highlighted in a different color, making it easier to identify important data points. This allows users to quickly and visually identify patterns and outliers in their data, making the analysis process more efficient and effective.


Often you may want to apply conditional formatting to a bar chart in Power BI so that bars with a value greater than a specific number have one color while bars with a value less than the number have another color:

Power BI conditional formatting for bar chart

Fortunately this is easy to do and the following example shows how to do so.

Example: Apply Conditional Formatting to Bar Chart in Power BI

Suppose we have the following dataset in Power BI that contains information about various basketball players:

Suppose that we would like to create a bar chart to visualize the sum of points scored by each team.

To do so, click the Report View icon on the left hand side:

Then click the icon called Line and stacked column chart under the Visualizations tab.

Then choose Team for the X-axis and Points for the Column y-axis:

This will create the following bar chart that displays the sum of points scored by players on each team:

Now suppose that we would like to apply conditional formatting to the bars such that the bars with a value of 100 or greater are blue and the bars with a value less than 100 are red.

To do so, click the Format your visual icon, then click the dropdown arrow next to Columns, then click the Conditional Formatting (fx) icon:

  • Format style: Gradient
  • What field should we base this on: Points
  • Minimum: Custom value of 99 with a red color
  • Maximum: Custom value of 100 with a blue color

Once you click OK, conditional formatting will be applied such that the bars with a value of 100 or greater are blue and the bars with a value less than 100 are red:

Power BI conditional formatting for bar chart

We have now successfully applied conditional formatting to the bar chart based on the numerical values of the bars.

Additional Resources

The following tutorials explain how to perform other common tasks in Power BI:

Power BI: How to Apply Conditional Formatting to Text Column

x