Remove duplicate lines
Use this tool to remove duplicate lines from a list. The first occurrence of each line is kept and later copies are removed, which is handy for email lists, keywords, or contacts.
With case-insensitive matching on, lines that differ only in capitalization count as duplicates. Blank lines are not checked for duplicates.
How to use
- Paste your line-based list into the input box.
- Turn on case-insensitive matching if you need it.
- Check the result and the number of removed lines.
How it works
The text is split into lines and read from top to bottom. The first time a line appears it is kept, and any later identical line is removed. With case-insensitive matching on, upper and lower case letters are treated as the same when comparing. Blank lines are skipped when looking for duplicates.
Example
Entering the lines apple, banana, apple, cherry, banana leaves apple, banana, and cherry, and the removed count shows 2. The lines "Apple" and "apple" count as different by default. With case ignored they count as the same, and only the first one, "Apple", is kept.
Good to know
- Lines must match exactly, including spaces, to count as duplicates. A trailing space makes a line different, so run the line cleanup tool first if needed.
- The original order is kept.
- Spreadsheet data is compared by the whole line. To compare one column, copy only that column.
Frequently asked questions
Does the original order change?
No. The first occurrence of each line keeps its position.
Are lines with different spaces duplicates?
No. Lines must match exactly, including spaces, to count as duplicates.
Is my list saved?
No. Everything runs in your browser.
Last updated: 2026-10-22