Conditional Formatting Not Equal – Excel & Google Sheets

Written by

Mel Jenkins

Reviewed by

Laura Tsitlidze

Last updated on July 31, 2023

This tutorial will demonstrate how to highlight cells that contain a value that is not equal to a specific value using Conditional Formatting in Excel and Google Sheets.


not equal to master


Highlight When Cells Do Not Equal

To highlight cells whose values are not equal to a specific value, you can create a Conditional Formatting custom formula using the following steps:

  1. Select the range you want to apply formatting to.
  2. In the Ribbon, select Home > Conditional Formatting > New Rule.


not equal to menu


  1. Select Use a formula to determine which cells to format, and enter the formula:


not equal to formula


  1. Cell G6 is the comparison value. It needs to be locked as an absolute cell reference. You can do this by adding $ signs to row and column indicators, or by pressing F4 on the keyboard.
  2. Click on the Format button and select your desired formatting.


Conditional formatting based on another cell formatting


  1. Click OK, then OK again to return to the Conditional Formatting Rules Manager.


not equal to rule manager


  1. Click Apply to format the selected range, then click Close or OK.


not equal to final


This formula entered will return TRUE when the cell contains any text and will therefore format the text in those cells accordingly.

Highlight When Cells Do Not Equal in Google Sheets

The process to highlight cells that do not equal a specific number in Google Sheets is similar to the process in Excel.

  1. Highlight the cells you wish to format, and then click on Format > Conditional Formatting.


google sheets not equal to menu


  1. The Apply to Range section will already be filled in.


google sheets not equal to range


  1. From the Format Rules section, select Custom Formula and type in the formula.


google sheets not equal formula correction


  1. Select the fill style for the cells that meet the criteria.


google sheets not equal to format


  1. Click Done to apply the rule.


google sheets not equal to final

AI Formula Generator

Try for Free

See all How-To Articles