How to use conditional formatting in Excel: cells above a value, duplicates, formula rules

Colour Excel cells above a value, highlight duplicates, write a rule with a formula, add colour scales and data bars, and manage or delete conditional formatting rules.

How to use conditional formatting in Excel: cells above a value, duplicates, formula rules

Conditional formatting helps when you want to see at a glance which figures in a sales table are above a certain number, which records appear twice in a list, or which values in a column are the highest. Instead of colouring cells by hand, you write a rule, and when a number changes the colour updates by itself.

This guide covers the Conditional Formatting menu on the Home tab, the built-in rules, rules written with a formula, colour scales and data bars, and how to manage and delete rules. The menu names follow Microsoft's Turkish support pages.

Reklam
  • Time10 minutes
  • DifficultyEasy
  • Steps10

🧰 What you need

  • The desktop version of Excel (Microsoft 365 or Excel 2016 and later) or Excel for the web
  • A worksheet containing numbers, text or dates

Steps

  1. Select the range and find the Conditional Formatting menuSelect the cells you want to colour; to cover a whole column, click its letter. On the Home tab, in the Styles group, click the arrow next to "Conditional Formatting". All the steps below start from this menu. The rule applies to the selected cells, and when you change a number, the colour updates by itself.
  2. Colour cells greater than a valueChoose "Conditional Formatting" → "Highlight Cells Rules" → "Greater Than" (in the Turkish interface the menu may appear as "Hücre Vurgulama Kuralları" or "Hücre Kurallarını Vurgula"). Type the threshold in the box, pick a format from the list next to it and click "OK". Cells above the threshold change colour at once. The same menu has commands such as "Between", "Equal To", "Text that Contains" for text and "A Date Occurring" for dates.
  3. Highlight the highest or lowest valuesSelect the range and open "Conditional Formatting" → "Top/Bottom Rules". Choose a command such as "Top 10 Items" or "Bottom 10%", change the number if needed and set a format. This is more practical when you do not know the threshold, for example to find the top 5 selling products.
  4. Highlight duplicate valuesSelect the range and click "Conditional Formatting" → "Highlight Cells Rules" → "Duplicate Values". In the box that opens, choose "Duplicate" or "Unique" in the left list, set a format and click "OK". This rule only colours duplicates and deletes nothing; removing rows is a separate job done with the remove-duplicates tool on the Data tab.
  5. Write your own rule with a formulaIf no built-in rule does the job, select the range and click "Conditional Formatting" → "New Rule". Under "Select a Rule Type" choose "Use a formula to determine which cells to format". Type the formula in the "Format values where this formula is true" box; it must start with an equals sign and return TRUE or FALSE. Example: with B2:B50 selected, type =B2>1000. Then click "Format", choose a fill or font colour in the "Format Cells" window and press "OK" in both windows.
  6. Get the cell reference right in the formulaThe formula is written for the top-left cell of the selected range and adapts to every other cell. To colour the whole row, select A2:E50 and type =$B2>1000; the $ sign before the column letter locks the column while the row number changes. One of Microsoft's examples shades every other row with =MOD(ROW(),2)=1. Check whether a reference is relative (B2) or absolute ($B$2); if it is wrong, the colours land on the wrong cells.
  7. Apply a colour scaleTo see how numbers are spread as a colour gradient, select the range and open "Conditional Formatting" → "Color Scales". Choose a two-colour or three-colour scale. Hover over the icons to see which one stands for which value; the top colour represents high values and the bottom colour low values. To change the colours, use the scale options in "New Rule".
  8. Add data barsSelect the range, open "Conditional Formatting" → "Data Bars" and click the bar style you like. A long bar means a high value and a short bar a low one. To hide the number and show only the bar, tick "Show Bar Only" while editing the rule. The same menu also has "Icon Sets", which add symbols such as arrows or traffic lights to cells.
  9. Manage and edit rulesClick "Conditional Formatting" → "Manage Rules" to open the "Conditional Formatting Rules Manager" window. If you do not see your rules, choose the right sheet in the "Show formatting rules for" list. Select a rule and use "Edit Rule" to change it, "Duplicate Rule" to copy it or "New Rule" to add one. When two rules conflict, the one higher in the list wins; the "Move Up" and "Move Down" arrows set the order. You can change the range a rule covers in the "Applies to" box.
  10. Clear and delete rulesTo clear only one area, select the cells and click "Conditional Formatting" → "Clear Rules" → "Clear Rules from Selected Cells". To clear the whole sheet, choose "Clear Rules from Entire Sheet" in the same menu. To delete a single rule, select it in the "Manage Rules" window and click the delete button. These actions only remove the colours; the data in the cells is untouched.

⚠ This guide is general information. Yudum cannot be held responsible for the outcome of following it; for official procedures always rely on the institution's own statement. Steps and fees change over time.

Was this guide helpful?
ShareWhatsAppXFacebook
💬 Comment on this articleShare what you think and join the comments below.Write a comment →

Related content

Reklam
50,8455,4866,57İstanbul4°

Yudum World

A village at the foot of Mount Kaf.

Create your character, stroll the square and meet people face to face. In your browser, free.

  • 🧑 Create your character
  • 🎲 Play a round at the coffeehouse
  • 🏠 Build a home with your group
Duel of the week
Yudum WorldA village at the foot of Mount Kaf is waiting for you.Join free →