Excel: How to Apply Conditional Formatting to Yes/No Values


You can apply conditional formatting to cells that contain Yes or No values in Excel by using the New Rule option under the Conditional Formatting dropdown menu within the Home tab.

The following example shows how to use this option in practice.

Example: Apply Conditional Formatting to Yes/No Values in Excel

Suppose we have the following dataset in Excel that shows whether or not various basketball players are All-Stars:

Suppose we would like to use conditional formatting to apply a green background to each cell with a value of “Yes” and a red background to each cell with a value of “No” in in the All-Star column.

To do so, we can highlight the range B2:B13, then click the Conditional Formatting dropdown menu on the Home tab and then click New Rule:

In the new window that appears, click Use a formula to determine which cells to format, then type =B2=”Yes” in the box, then click the Format button and choose a green fill color to use.

Once we press OK, all of the cells in the range B2:B13 that contain a value of “Yes” will be highlighted with a green background:

Next, highlight the range B2:B13 again and then click the Conditional Formatting dropdown menu on the Home tab and then click New Rule.

Then click Use a formula to determine which cells to format, then type =B2=”No” in the box, then click the Format button and choose a red fill color to use.

Once we press OK, all of the cells in the range B2:B13 that contain a value of “No” will be highlighted with a red background:

Excel conditional formatting for yes or no values

Note: Within the Format options, you can also change the font style and border style of cells if you’d like.

Additional Resources

The following tutorials explain how to perform other common operations in Excel:

Excel: Apply Conditional Formatting Based on Multiple Text Values
Excel: Apply Conditional Formatting Based on Multiple Conditions
Excel: Apply Conditional Formatting if Cell is Between Two Dates

Leave a Reply

Your email address will not be published. Required fields are marked *