What this tool does
Remove duplicate lines walks through your text from top to bottom, one line at a time, and drops any line that has already appeared. It always keeps the first occurrence of each line and deletes the later repeats. The result is a clean list with no identical rows, ready to copy. Everything happens inside your browser — your text is never uploaded.
Unlike simply sorting a list, the goal here is not to change the order but to strip out what repeats. That is why you can choose to keep the original order exactly as it was (handy when the order carries meaning, like a chronological log) or, if you prefer, sort the result A to Z along the way.
It fits plenty of everyday jobs: cleaning a mailing list before a send, removing duplicates from data exported out of a spreadsheet, unifying repeated tags or categories, or tidying a list of URLs.
How to use it
- Paste or type your text in the first box, with one item per line.
- Adjust the options to match what you count as a “duplicate”:
- Case sensitive: when off (the default),
Annaandannacount as the same line. - Ignore leading and trailing spaces: trims each line before comparing, so
louisandlouisare treated as equal. - Remove empty lines: drops blank rows from the result.
- Case sensitive: when off (the default),
- Pick the result order: keep the original or sort A → Z.
- Press Remove duplicates. Below you get the clean text and three counters: original lines, unique lines, and duplicates removed. Copy with one click.
How it decides what is a duplicate
For each line the tool builds a comparison “key”. If you turn on Ignore spaces, the key is the trimmed line; if you turn off Case sensitive, the key is lowercased using the language’s rules. Two lines with the same key are duplicates and only the first one survives.
This is why the same lines can give different results depending on the options:
| Options | Unique lines | Reason |
|---|---|---|
| Case-insensitive + ignore spaces | 3 | Anna@… and louis merge with their twins |
| Case sensitive + keep spaces | 5 | anna@… ≠ Anna@… and louis ≠ louis |
Worked example
Paste this eight-line list (note the capital in Anna, the stray spaces around one louis, the repeated louis, the blank line, and the trailing anna):
anna@mail.com
Anna@mail.com
louis@mail.com
louis@mail.com
mary@mail.com
louis@mail.com
anna@mail.com
With the default options (case-insensitive, ignore spaces, remove empty, keep order), the result is 3 lines and 5 are removed:
anna@mail.com
louis@mail.com
mary@mail.com
It kept anna@mail.com (the first), dropped Anna@mail.com (same line when case is ignored), the three extra copies of louis@mail.com (one carried spaces), and the blank line. If you instead turn on Case sensitive and turn off Ignore spaces, you get 5 lines, because Anna@mail.com and louis@mail.com now count as different.
Frequently asked questions
How is this different from “Sort lines”?
The focus differs. Here the main job is to strip repeats, and by default the original order of the lines is preserved. Sorting is just an extra option. If what you want is to reorder, shuffle, or reverse a list, use the sort-lines tool instead.
Which copy of each duplicate is kept?
Always the first occurrence, counting from the top. The later ones are discarded. That is why the order you paste in matters: if you want to keep a specific version, place it before its repeats.
Does it care about case and accents?
By default it is case-insensitive, so LONDON and london are the same line. Accents do count: resume and résumé are different, because they are different strings. Turn on Case sensitive when you need to separate iPhone from iphone.
Is my text stored or sent anywhere?
No. All processing runs in your browser with JavaScript; nothing travels to a server. Close the tab and no trace of what you pasted is left behind.