Cell background color

New Contributor

Is there a formula for having a cell change background color if a different cell shows a specific value?

Ex: If I want cell A1 to turn "yellow" when cell A5 shows the word "Caution", is there a formula that would allow me to do that?

2 Replies
best response confirmed by Sergei Baklan (MVP)


You can do this using conditional formatting:

Select A1
On the Home tab of the ribbon, click Conditional Formatting > New Rule...
Select 'Use a formula to determine which cells to format'.
Enter the formula




Click Format...
Activate the Fill tab.
Select yellow.
Click OK, then click OK again.

@Hans Vogelaar 

Thank you!