Excel’s Data Validation feature does not color cells by itself. To color a cell according to its value or flag an invalid entry, create a Data Validation rule and then add a separate rule under Home > Conditional Formatting; the conditional formatting rule controls the color.
What Data Validation does—and what it does not do
Data Validation sets limits on what people can enter in a cell. For example, it can offer a dropdown list of project statuses, restrict an entry to a date range, or display an error when someone types a value outside the permitted range. It is an entry-control feature, not a formatting feature: its settings do not assign a fill color or font color when a value is selected.
Conditional Formatting is the companion feature for visual feedback. It evaluates a cell’s value or a formula and applies formatting when a condition is true. A dropdown can therefore supply choices while conditional formatting colors those choices—for example, a cell turns green for “Done” and amber for “In progress.” The two features are configured separately, even though they can work together in the same range.
This distinction also explains a common misconception: changing a cell’s fill color manually does not change its allowed entries, and setting a validation rule does not automatically make invalid values red. For those behaviors, configure the relevant validation and formatting rules explicitly.
Set up a dropdown and color its choices
In Excel for Microsoft 365 on Windows, select the cells that need a dropdown, then choose Data > Data Validation. On the Settings tab, choose List under Allow, enter the permitted choices in Source, and leave In-cell dropdown selected. For a short list, Source can contain comma-separated items such as Open,In progress,Done. For a list maintained elsewhere, select a range of cells as the source instead. Select OK to apply the validation.
Next, select the same input range and choose Home > Conditional Formatting > New Rule. To color one exact status, choose “Format only cells that contain,” set the rule to specific text containing the status, and use Format to choose a fill. Repeat for other statuses, selecting a different fill each time. If partial matches could cause confusion, use a formula rule rather than the “Text that Contains” option.
For an exact-match formula, suppose the status cells are A2:A100. Select that range, create a new rule with “Use a formula to determine which cells to format,” and enter =A2="Done". Choose a green fill. The reference starts at A2 because that is the top-left cell of the selected range; Excel adjusts the row reference for each cell. Create another rule for “In progress” if that status needs a different color.
To color an entire row based on its status, suppose each record occupies A2:F100 and the status is in column A. Select A2:F100 and use =$A2="Done" as the formula. The dollar sign fixes the status column while the row number changes for each record. In Excel for Mac, the same features are available from the Home and Data tabs, although the dialogs and ribbon layout can look slightly different.
Color invalid entries, not just selected values
A validation error alert is useful when someone types an invalid value, but it does not provide a persistent color for every cell that contains an invalid value. A conditional formatting rule can make those exceptions easy to spot, including values that were already present before validation was added.
For example, suppose permitted statuses are listed in D2:D4, and users enter statuses in A2:A100. Apply a formula-based conditional formatting rule to A2:A100 using =AND(A2<>"",COUNTIF($D$2:$D$4,A2)=0), then choose a red fill. The rule leaves blank cells uncolored and flags a nonblank entry that does not appear in the permitted list. The dollar signs keep the permitted range fixed while the entry reference changes down the selected range.
That formula is useful for ordinary text choices, but it is worth checking special cases. COUNTIF treats asterisks and question marks in criteria as wildcard characters, so a permitted item containing those characters may need a different check. Also decide whether letter case matters: COUNTIF is not case-sensitive. For a simple list without wildcard characters, it is a practical way to highlight exceptions.
Excel’s Data Validation menu also includes Circle Invalid Data in desktop versions. This temporarily circles values that fail the validation rule and can help with a quick audit. It is not the same as a fill color, and it is less useful as a lasting visual indicator than conditional formatting. The circles can be cleared from the same menu.
Choose a useful rule for each kind of data
The best color rule depends on what the validation is checking. A status list usually benefits from a distinct color for each meaningful state. A numeric range may need only one warning color for values outside a threshold, while a date field might use color to distinguish overdue dates from upcoming ones. Keep the color tied to a clear meaning rather than decorating every possible value.
- Dropdown categories: Use one conditional formatting rule per category when the list is short and the colors communicate a real distinction.
- Numeric limits: Use a formula or a built-in conditional formatting rule to call attention to high or low values. Keep the validation rule responsible for restricting entry.
- Missing required values: If blank cells should be flagged, create a separate blank-cell rule. Do not use a rule that ignores blanks if completing the field is part of the task.
- Row-level status: Apply a formula rule to the full record range and lock the status column, so the whole row changes consistently.
For example, a team tracker might use validation to limit a Status column to Open, In progress, and Done. Conditional formatting can then use restrained fills to distinguish those states, while a separate rule highlights missing owners. A reader should be able to understand what a color means without relying on color alone; keep the text visible and consider labels, icons, or a legend for readers who may not distinguish the chosen colors.
Validation settings and formatting rules are independent
When setting up Data Validation, choose the error behavior deliberately. On the Error Alert tab, Excel offers Stop, Warning, and Information styles. Stop blocks an invalid typed entry when the alert is enabled; Warning and Information allow the user to proceed after a confirmation. The Input Message tab can show instructions when someone selects a cell. These options affect entry behavior, not cell color.
Conditional formatting has its own scope and priority. In the New Formatting Rule dialog, check that the Applies to range covers the intended cells. If two rules apply to the same cell, their order and any “Stop If True” setting can affect which formatting appears. A rule that fills a whole row should usually be applied to the full row range, while the formula refers only to the status cell.
Validation also is not a complete security barrier. Copying and pasting data, filling cells, importing content, or using other workbook operations can introduce values without the same experience as typing into a validated cell. For important workbooks, combine entry restrictions with review checks, conditional formatting, and sensible controls over who can edit the data.
Common problems and how to fix them
- No color appears: Check that the conditional formatting rule exists, that its condition matches the cell’s actual value, and that the Applies to range includes the cell. A trailing space or a slightly different status spelling can make an exact-match rule evaluate as false.
- The wrong cells change color: Review the formula’s relative and absolute references. For a rule applied to A2:A100, a formula beginning with A2 is usually appropriate. For a rule applied across rows using column A, lock the column as in
=$A2="Done". - Invalid values are not blocked: Open Data > Data Validation and inspect the Error Alert tab. Confirm that the alert is enabled and set to Stop if users must not proceed after an invalid typed entry. Pasted data may still require a separate audit.
- The dropdown works but the color does not: The dropdown is controlled by Data Validation, while the fill is controlled by Conditional Formatting. Creating one does not create the other.
- Old values remain uncolored: Existing entries are not necessarily corrected when you add validation. Use conditional formatting or Circle Invalid Data to find values that do not comply, then review and correct them.
When a workbook has many overlapping rules, open Home > Conditional Formatting > Manage Rules. In the rules manager, inspect which cells each rule applies to and whether a higher-priority rule prevents a later one from showing. Editing the rule is often safer than adding more rules on top of it.
Make the colors readable and maintainable
Color is most useful when it communicates a small number of meaningful states. If every category has a similar shade, readers may not be able to tell them apart. Use strong contrast between text and fill, avoid relying on red-versus-green alone, and preserve the underlying status text so a color is never the only source of information. A short note near the table can explain the scheme.
For a workbook that will grow, consider keeping dropdown choices in a dedicated reference area rather than typing a long list into each validation rule. That makes it easier to update the allowed options consistently. After changing the source list, check that the validation source still covers the intended entries and that any conditional formatting rules still represent the revised categories.
On Excel for the web, the available controls and dialogs can differ from the Windows desktop instructions, especially for managing complex rules. The core principle remains the same: use Data Validation to control entries and Conditional Formatting to display colors. If a rule is difficult to edit in the browser, open the workbook in the desktop app and review it there.
Frequently Asked Questions
Can Data Validation automatically color a cell in Excel?
No. Data Validation restricts or guides entries, but it does not apply fill colors. Create a separate rule under Home > Conditional Formatting to color cells based on their values or a formula.
Can I color a dropdown cell as soon as someone selects an option?
Yes. Create conditional formatting rules for the dropdown’s possible values. The cell changes color when its current value meets a rule; merely opening or selecting the dropdown does not trigger a color based on a choice that has not been entered.
How do I highlight values that do not match my dropdown list?
Apply a formula-based conditional formatting rule to the entry range. For a list stored in D2:D4 and entries starting in A2, a rule such as =AND(A2<>"",COUNTIF($D$2:$D$4,A2)=0) highlights nonblank entries absent from that list. Adjust the references to match your layout.
Will validation stop invalid data from being pasted?
Do not assume it will. Pasting or other workbook operations can bypass the normal typed-entry warning. Use a conditional formatting check, Circle Invalid Data, or another review process to find exceptions after data is added.
Can one status color an entire row?
Yes. Select the full record range and create a formula rule that locks the status column while leaving the row relative. If the status is in A2 and the selected range begins on row 2, =$A2="Done" colors rows whose status is Done.
Related
- AG Grid Insert Row: APIs, Examples, and Row Model Tips
- COUNTA in Excel: What It Counts and How to Use It
- ISNUMBER in Excel: What It Checks and How to Use It
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Google Sheets: Count Dropdown Values in a Column EasilyTo count how many times a particular dropdown choice appears in Google Sheets, use =COUNTIF(B2:B100,"Approved"), replacing the range…
- Excel Import Data from Multiple CSV FilesTo import data from multiple CSV files into Excel for Microsoft 365 on Windows, put the files in…
- How to Format Tick Boxes in Excel for Clear ChecklistsTo format a tick box in Excel, select the checkbox cell and use the Home tab to apply…
- Export Outlook Contacts: Steps, Formats, and TipsTo export Microsoft Outlook contacts, open the People or Contacts area and use its export command to save…
- How to Archive Emails in Outlook 365To archive email in Outlook 365, select a message and choose Archive on the toolbar or ribbon. Outlook…
- Excel Cell Character Limit: What 32,767 Really MeansAn Excel cell can contain up to 32,767 characters. That is the maximum stored in one cell in…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.