How to Find Duplicates in Excel
The fastest way to find duplicates in Excel is Conditional Formatting:
- Select the range you want to check.
- Go to Home > Conditional Formatting > Highlight Cells Rules > Duplicate Values.
- Choose a highlight color.
- Click OK.
That highlights duplicate values without deleting anything. If you need a
filterable review column, use COUNTIF instead:
=IF(COUNTIF($A$2:$A$100,A2)>1,"Duplicate","Unique")Use this guide when you want to find and review duplicates first. When you are ready to delete them, use How to Remove Duplicates in Excel.
1. Choose the Right Duplicate Check
Not every duplicate problem is the same. Start by deciding what "duplicate" means in your sheet.
| Need | Best method |
|---|---|
| Highlight repeated values quickly | Conditional Formatting |
| Filter duplicate rows for review | COUNTIF helper column |
| Check duplicates across multiple columns | COUNTIFS or a helper key |
| Find values repeated in two separate lists | Compare columns with COUNTIF |
| Delete duplicates after review | Remove Duplicates tool |
The most important question is: which column or columns define a duplicate? For customers, it might be Email. For orders, it might be Order ID. For survey exports, it might be Respondent ID plus Timestamp.
2. Example Data
Suppose you have this customer list:
| Customer ID | Region | Status | |
|---|---|---|---|
| C-101 | maya@example.com | East | Active |
| C-205 | leo@example.com | West | Active |
| C-101 | maya@example.com | East | Active |
| C-318 | nora@example.com | North | Inactive |
| C-427 | leo@example.com | South | Active |
There are two possible duplicate questions:
| Question | Duplicate definition |
|---|---|
| Is Customer ID repeated? | Customer ID |
| Is Email repeated? | Email |
The answer depends on the business rule. One repeated email might be a true duplicate, or it might be a shared team inbox.
3. Highlight Duplicates with Conditional Formatting
Use this when you want to visually scan duplicates without changing the data.
Steps:
- Select the range, such as
A2:A100. - Go to Home > Conditional Formatting.
- Choose Highlight Cells Rules > Duplicate Values.
- Pick a format, such as a red fill.
- Click OK.
Excel highlights all values that appear more than once.
This is best for quick review, but it does not create a filterable status column. If you need to sort or filter duplicate rows, use a helper formula.
For more visual rule examples, see Excel Conditional Formatting.
4. Find Duplicates with COUNTIF
Use COUNTIF when you want a helper column that says Duplicate or Unique.
=IF(COUNTIF($A$2:$A$100,A2)>1,"Duplicate","Unique")Result:
| Customer ID | Duplicate? |
|---|---|
| C-101 | Duplicate |
| C-205 | Unique |
| C-101 | Duplicate |
| C-318 | Unique |
How it works:
| Formula part | Meaning |
|---|---|
$A$2:$A$100 |
The column to check |
A2 |
The current value |
>1 |
More than one occurrence means duplicate |
"Duplicate" |
Label for repeated values |
For more COUNTIF examples, see the
Excel COUNT function tutorial.
If you are deciding between COUNTIF and COUNTIFS, see
COUNTIF vs COUNTIFS in Excel.
5. Show Only the Second and Later Duplicates
Sometimes you want to keep the first occurrence and flag only later repeats. Use a growing range:
=IF(COUNTIF($A$2:A2,A2)>1,"Repeat","First")Result:
| Customer ID | Status |
|---|---|
| C-101 | First |
| C-205 | First |
| C-101 | Repeat |
| C-318 | First |
This is useful when you plan to keep the first row and review only the repeats.
6. Find Duplicate Rows Across Multiple Columns
If a duplicate is defined by more than one column, use COUNTIFS.
Example: find rows where both Customer ID and Email repeat:
=IF(COUNTIFS($A$2:$A$100,A2,$B$2:$B$100,B2)>1,"Duplicate row","Unique")This checks both criteria at the same time.
| Customer ID | Result | |
|---|---|---|
| C-101 | maya@example.com | Duplicate row |
| C-205 | leo@example.com | Unique |
| C-101 | maya@example.com | Duplicate row |
| C-427 | leo@example.com | Unique |
If the formula gets hard to read, create a helper key:
=A2&"|"&B2Then run COUNTIF against the helper key column.
7. Find Duplicates Between Two Lists
If you have two separate lists and want to find values that appear in both, use the same comparison pattern as a found/missing check:
=IF(COUNTIF($D$2:$D$100,A2)>0,"Also in List 2","Only in List 1")Use this when comparing customer lists, product IDs, invoice numbers, or exports from two systems.
For the full workflow, see How to Compare Two Columns in Excel.
8. Filter and Review Duplicate Rows
After adding a helper column, turn on filters:
- Select your table.
- Go to Data > Filter.
- Open the filter on the helper column.
- Select only
DuplicateorRepeat. - Review those rows before deleting anything.
This review step matters because not every repeated value is a mistake.
| Repeated value | Possible meaning |
|---|---|
| Same customer email | Duplicate customer or shared inbox |
| Same product ID | Duplicate product or multiple orders |
| Same invoice number | Duplicate invoice or correction row |
| Same name | Different people with the same name |
9. Common Reasons Duplicates Are Missed
Excel compares values exactly. If duplicates are not found, check the data first:
| Problem | Example | Fix |
|---|---|---|
| Extra spaces | Acme Inc vs Acme Inc |
Use TRIM |
| Different case | north vs North |
Standardize case |
| Different punctuation | A-100 vs A100 |
Standardize IDs |
| Numbers stored as text | 1001 text vs 1001 number |
Convert data types |
| Hidden characters | Imported CSV or web data | Use CLEAN |
For a broader cleanup workflow, see Excel Data Cleaning. When inconsistent punctuation or labels need a one-time standardization, use Find and Replace in Excel before checking duplicates again.
10. Find Duplicates Without Removing Them
Use this workflow when the data is important:
- Add a helper column with
COUNTIForCOUNTIFS. - Filter to
DuplicateorRepeat. - Review the business meaning of each repeated row.
- Copy the duplicate rows to a review sheet if needed.
- Remove duplicates only after you know which rows are safe to delete.
This keeps the review step separate from the deletion step.
11. When to Remove Duplicates
Finding duplicates and removing duplicates are different tasks.
| Task | Best guide |
|---|---|
| Highlight or flag duplicates | This guide |
| Delete repeated rows safely | How to Remove Duplicates in Excel |
| Clean inconsistent text before checking duplicates | Excel Data Cleaning |
| Compare two separate lists | How to Compare Two Columns in Excel |
Do not jump straight to deletion if the duplicate definition is unclear. Find and review the duplicates first.
12. Practice Example
Use this table:
| Order ID | Customer | Amount |
|---|---|---|
| O-101 | Maya | 120 |
| O-205 | Leo | 240 |
| O-101 | Maya | 120 |
| O-318 | Nora | 180 |
| O-427 | Leo | 300 |
Tasks:
| Task | Formula |
|---|---|
| Flag repeated Order IDs | =IF(COUNTIF($A$2:$A$6,A2)>1,"Duplicate","Unique") |
| Flag only later repeats | =IF(COUNTIF($A$2:A2,A2)>1,"Repeat","First") |
| Flag duplicate Order ID plus Customer | =IF(COUNTIFS($A$2:$A$6,A2,$B$2:$B$6,B2)>1,"Duplicate row","Unique") |
Reference answers:
| Order ID | Customer | Duplicate ID? |
|---|---|---|
| O-101 | Maya | Duplicate |
| O-205 | Leo | Unique |
| O-101 | Maya | Duplicate |
| O-318 | Nora | Unique |
| O-427 | Leo | Unique |
13. Summary
To find duplicates in Excel, use Conditional Formatting for a quick visual
check, COUNTIF for a filterable helper column, and COUNTIFS when a duplicate
depends on multiple columns. Clean spaces and inconsistent formats before
trusting the result, then review duplicate rows before using the Remove
Duplicates tool.
14. Related Guides
- Delete duplicate rows safely with How to Remove Duplicates in Excel.
- Compare two lists with How to Compare Two Columns in Excel.
- Clean messy data before checking duplicates with Excel Data Cleaning.
- Highlight duplicate values visually with Excel Conditional Formatting.
- Learn more
COUNTIFandCOUNTIFSpatterns in the Excel COUNT function tutorial. - Choose between single-condition and multi-condition counts with COUNTIF vs COUNTIFS in Excel.
Was this guide helpful?
If something is missing or unclear, open an issue and we will improve it.
Send feedback