Open an Excel or CSV file, pick the columns that define a duplicate and remove the repeated rows, highlight them in red, or pull out only the duplicates. You can keep the first or the last copy, ignore letter case and stray spaces, and download a clean .xlsx.
Last updated:
Compare these columns
What to do with duplicates
Which copy to keep
Matching
Advertisement
Advertisement
How to use the Remove Duplicates in Excel
Open your file by dropping it on the box or clicking it. A sample customer list is loaded so you can see how it works.
Pick the worksheet if the workbook has several, and untick the header option if row 1 is data.
Choose the columns to compare: leave all selected to find fully identical rows, or select only a key such as Email.
Choose the action (remove, highlight or keep only duplicates) and whether to keep the first or the last copy.
Check the preview: duplicates are shown in red with the row they repeat.
Download the cleaned file as .xlsx or CSV.
How duplicates are detected
For every data row the tool builds a key from the columns you selected. Two rows are duplicates when their keys are equal. With all columns selected that means the whole row matches; with one column selected only that value has to match. The first row with a given key (or the last, if you choose so) is the one that is kept; every other row with the same key is a duplicate of it.
Values are compared as they appear in the cell: numbers by value (5 and 5.0 are equal), dates by their date and time, and text character by character, optionally ignoring case and repeated or surrounding spaces. Rows whose key columns are all empty are skipped unless you untick the blank-row option.
Choose Keep last occurrence in the second case and row 5 (the Pro plan) is kept instead of row 3, which is the usual choice when later rows hold newer information.
Doing it in Excel itself
Remove: select the range, then Data > Remove Duplicates, and tick the columns to compare. Excel always keeps the first occurrence and changes your sheet in place.
Highlight: Home > Conditional Formatting > Highlight Cells Rules > Duplicate Values. This colours every occurrence, including the first, and works on single cells rather than whole rows.
Formula: in Excel 365, =UNIQUE(A2:E100) returns the distinct rows of a range, and =COUNTIFS(A:A,A2)>1 flags rows whose value in column A appears more than once.
This tool gives the same result without touching the original workbook, and adds keep-last, case/space-insensitive matching and a status column that names the row each duplicate repeats.
Frequently asked questions
How do I remove duplicate rows from an Excel file?
Open the file, leave all columns selected under Compare these columns and keep Remove duplicate rows chosen. Every row that is identical to an earlier row is dropped and the first copy is kept. Click Download cleaned file to save the result as .xlsx or CSV.
How do I remove duplicates based on one column only?
Click None under Compare these columns and tick just the column that should be unique, such as Email or Order ID. Rows are then treated as duplicates when that column matches, even if other columns differ, and only the first (or last) row for each value is kept.
What is the difference between keeping the first and the last occurrence?
When several rows share the same key, Keep first keeps the one nearest the top of the sheet and Keep last keeps the one nearest the bottom. Keeping the last copy is useful when newer records are appended at the end, for example to keep the latest address for each customer.
Can I highlight duplicates instead of deleting them?
Yes. Choose Highlight duplicates: all rows are kept, the repeated copies are filled light red in the downloaded .xlsx and a Duplicate status column says which row each one repeats. CSV files cannot store colours, so the status column is the marker there.
Why are two rows that look the same not detected as duplicates?
They usually differ in hidden ways: extra spaces, different capitalisation, a number stored as text, or a date with a time part. Turn on Ignore upper/lower case and Ignore spaces, and check that the values really are identical in the preview. Dates are compared by their calendar value, so 2025-01-04 and 2025-01-04 13:30 are different.
Does this work like Excel's Remove Duplicates button?
It follows the same rule as Data > Remove Duplicates in Excel (a row is removed when the selected columns match an earlier row), but adds options Excel lacks: keeping the last copy, ignoring case and spaces, highlighting instead of deleting, and extracting only the duplicated rows. Your original file is never changed.
Is my spreadsheet uploaded?
No. The file is read and processed with JavaScript in your browser and the cleaned file is created on your device, so customer lists and other private data stay with you.
Are all the tools on FreeToolCabin tested for quality and accuracy?
Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.