Conditional formatting and simple dashboards
Make important numbers stand out automatically with conditional formatting: highlight rules, top and bottom values, data bars, icon sets and formula-based rules, then combine them into a one-page dashboard.
🎯 By the end of this lesson you will be able to:
- Highlight cells with built-in conditional formatting rules
- Write a formula rule that colours whole rows
- Lay out a simple one-page dashboard with key numbers, a table and a chart
Outline
What you'll learn and why it matters
In a sheet of hundreds of numbers, the ones that need attention get lost: the overspent budget, the late invoice, the best seller. Conditional formatting colours cells automatically based on their values, and the colours update when the numbers change. It turns a grid into something you can read at a glance.
Built-in rules
- Select the cells, such as the Actual column of the Budget sheet.
- Choose Home → Conditional Formatting.
- Pick a rule type, enter the value and choose a format, then click OK (or Done).
| Rule | Example | Use it for |
|---|---|---|
| Highlight Cells → Greater Than | Actual greater than 8,000 | Values above or below a limit |
| Highlight Cells → Duplicate Values | Repeated emails | Finding duplicates before removing them |
| Top/Bottom → Top 10 Items (set to 3) | The 3 biggest orders | Best and worst performers |
| Data Bars | A bar inside each cell, sized by value | Comparing sizes without a chart |
| Color Scales | Green to red by value | Spotting high and low areas in a large table |
| Icon Sets | Arrows or traffic lights | Showing status, such as up, flat or down |
Formula rules: colour whole rows
To colour a whole row when one of its cells meets a condition, use Conditional Formatting → New Rule → Use a formula to determine which cells to format. Select the whole data area (A2:D10) first, and write the formula for the first row, locking the column with $:
Worksheet: Budget
| Row | A | B | C | D | E |
|---|---|---|---|---|---|
| 1 | Month | Category | Planned | Actual | Over budget? (the rule's test) |
| 2 | Jan | Rent | 15000 | 15000 | FALSE |
| 3 | Jan | Food | 8000 | 8650 | TRUE |
| 4 | Jan | Travel | 3000 | 2400 | FALSE |
| 5 | Feb | Rent | 15000 | 15000 | FALSE |
| 6 | Feb | Food | 8000 | 7900 | FALSE |
| 7 | Feb | Travel | 3000 | 3600 | TRUE |
| 8 | Mar | Rent | 15000 | 15000 | FALSE |
| 9 | Mar | Food | 8000 | 8200 | TRUE |
| 10 | Mar | Travel | 3000 | 2950 | FALSE |
Formulas (green cells)
- E2 =$D2>$C2 → FALSE
- E3 =$D3>$C3 → TRUE
- E4 =$D4>$C4 → FALSE
- E5 =$D5>$C5 → FALSE
- E6 =$D6>$C6 → FALSE
- E7 =$D7>$C7 → TRUE
- E8 =$D8>$C8 → FALSE
- E9 =$D9>$C9 → TRUE
- E10 =$D10>$C10 → FALSE
Excel checks the formula for every cell in the selection, adjusting the row number each time. $D2 means *always column D, but the current row*, so each cell in a row looks at that row's Actual and Planned values.
A simple one-page dashboard
A dashboard puts the most important numbers, one summary table and one or two charts on a single screen, so a manager can see how things are going without scrolling. Keep it on its own sheet and build it from formulas and PivotTables that refer to the data sheets.
| Part | Example | Built with |
|---|---|---|
| Key numbers (KPIs) at the top | Total sales, number of orders, average order value | SUM, COUNT, AVERAGE, SUMIFS |
| A summary table | Sales by region | PivotTable or SUMIFS |
| A chart | Revenue by month | Line chart from a summary |
| Highlights | Regions below target in red | Conditional formatting |
| A filter | Choose a salesperson | A Data Validation drop-down that the formulas refer to, or a Slicer |
You will build exactly this in the final project.
Practice
Guided exercise
Highlight the overspends
In the Budget sheet, make every Actual value that is greater than its Planned value show in light red.
- Select D2:D10.
- Home → Conditional Formatting → New Rule → Use a formula.
- Enter
=D2>C2, choose a light red fill, and click OK.
Show the solution
Worksheet: Budget
| Row | A | B | C | D | E |
|---|---|---|---|---|---|
| 1 | Month | Category | Planned | Actual | Rule result |
| 2 | Jan | Rent | 15000 | 15000 | FALSE |
| 3 | Jan | Food | 8000 | 8650 | TRUE |
| 4 | Jan | Travel | 3000 | 2400 | FALSE |
| 5 | Feb | Rent | 15000 | 15000 | FALSE |
| 6 | Feb | Food | 8000 | 7900 | FALSE |
| 7 | Feb | Travel | 3000 | 3600 | TRUE |
| 8 | Mar | Rent | 15000 | 15000 | FALSE |
| 9 | Mar | Food | 8000 | 8200 | TRUE |
| 10 | Mar | Travel | 3000 | 2950 | FALSE |
Formulas (green cells)
- E2 =D2>C2 → FALSE
- E3 =D3>C3 → TRUE
- E4 =D4>C4 → FALSE
- E5 =D5>C5 → FALSE
- E6 =D6>C6 → FALSE
- E7 =D7>C7 → TRUE
- E8 =D8>C8 → FALSE
- E9 =D9>C9 → TRUE
- E10 =D10>C10 → FALSE
How to get there: With only column D selected, the rule needs no $: each cell compares itself with the planned value beside it. Three cells turn red: Food in January, Travel in February and Food in March.
Your turn
Mark the top 3
In a list of the ten orders' totals, highlight the three largest with a Top/Bottom rule. Which three totals are highlighted?
Show the solution
Worksheet: Totals
| Row | A | B | C |
|---|---|---|---|
| 1 | Order | Total | Rank |
| 2 | ORD-1001 | 3300 | 3 |
| 3 | ORD-1002 | 1000 | 8 |
| 4 | ORD-1003 | 900 | 9 |
| 5 | ORD-1004 | 1080 | 7 |
| 6 | ORD-1005 | 240 | 10 |
| 7 | ORD-1006 | 2000 | 5 |
| 8 | ORD-1007 | 3000 | 4 |
| 9 | ORD-1008 | 4800 | 1 |
| 10 | ORD-1009 | 1320 | 6 |
| 11 | ORD-1010 | 4000 | 2 |
Formulas (green cells)
- C2 =COUNTIF($B$2:$B$11,">"&B2)+1 → 3
- C3 =COUNTIF($B$2:$B$11,">"&B3)+1 → 8
- C4 =COUNTIF($B$2:$B$11,">"&B4)+1 → 9
- C5 =COUNTIF($B$2:$B$11,">"&B5)+1 → 7
- C6 =COUNTIF($B$2:$B$11,">"&B6)+1 → 10
- C7 =COUNTIF($B$2:$B$11,">"&B7)+1 → 5
- C8 =COUNTIF($B$2:$B$11,">"&B8)+1 → 4
- C9 =COUNTIF($B$2:$B$11,">"&B9)+1 → 1
- C10 =COUNTIF($B$2:$B$11,">"&B10)+1 → 6
- C11 =COUNTIF($B$2:$B$11,">"&B11)+1 → 2
How to get there: Home → Conditional Formatting → Top/Bottom Rules → Top 10 Items, then change 10 to 3. The highlighted totals are 4,800, 4,000 and 3,300. The Rank column (1 = largest) confirms it: =COUNTIF($B$2:$B$11,">"&B2)+1 counts how many totals are bigger, plus one. (Excel also has a RANK function that does the same.)
Common mistakes
Missing $ in a row-colouring formula
You see: Only one column changes colour, or the wrong rows do
Fix: Lock the column: =$D2>$C2, and write it for the first row of the selection.
Writing the formula for the wrong starting row
You see: Colours are shifted up or down by a row
Fix: The formula must refer to the top-left cell of the selected range.
Too many colours
You see: Nothing stands out any more
Fix: Highlight only what needs action.
Colour as the only signal
You see: Some readers cannot see the difference
Fix: Add a text status column or icons as well.
Recap
- Conditional formatting colours cells automatically and updates with the data.
- Built-in rules: highlight cells, top/bottom, duplicates, data bars, colour scales, icon sets.
- Formula rules with $ on the column colour whole rows; write the formula for the first row.
- A dashboard shows KPIs, one summary, a chart and highlights on one page.
Key terms
- Conditional formatting
- Formatting that is applied automatically when a cell meets a condition.
- Data bars
- Bars drawn inside cells whose length shows the size of the value.
- KPI
- Key performance indicator: a headline number that shows how something is doing.
- Dashboard
- A one-page view of the most important numbers, tables and charts.
Check your understanding
Answer all 4 questions, then check your answers to see an explanation for each one.
1. What happens to conditional formatting when a value changes?
2. To colour whole rows A2:D10 when Actual (D) exceeds Planned (C), which rule formula is right?
3. Which rule shows a bar inside each cell sized by its value?
4. What belongs at the top of a dashboard?
Mark this lesson complete
Finished this lesson?
When you have worked through the examples and exercises, mark it complete to save your progress.