Remove duplicate lines
Keep the first occurrence of every line.
Your result will appear here.
Enter your input, then run the tool.How to use the remove duplicate lines
Clean a list without sorting it: every line that has already appeared is dropped and the first occurrences stay in their original order.
Paste the lines, run the tool and copy or download the result.
- Paste your list into the Input box, one item per line.
- Press Run tool.
- Copy the result with Copy result, or download it as a text file.
Good to know
- Matching is exact and case-sensitive: Apple and apple are different lines.
- Leading or trailing spaces make lines different too; clean the text first if needed.
- Blank lines are also reduced to one.
- Up to 500,000 characters of text.
- Your text stays in your browser and is never uploaded.
Examples
- apple, banana, apple, Apple and cherry on separate lines become apple, banana, Apple, cherry: the second “apple” goes, but “Apple” stays because capitals differ.
If something goes wrong
Lines that look the same were not removed.
They differ in an invisible way, usually a trailing space or a capital letter. Run the text cleaner first to trim spaces, then remove duplicates.
The end of a very long list is missing.
The box holds up to 500,000 characters and cuts off anything pasted beyond that. Split the list and run it in parts.
Questions
Can I ignore case?
Not directly. Run the case converter first to make every line lower case, then remove duplicates.
Does it keep the order?
Yes. The first occurrence of each line stays where it was.
Does it remove duplicate words inside a line?
No. Whole lines are compared.
How can I tell how many lines were removed?
The tool does not count them. Paste the list before and after into the word counter and compare the line counts.
Next steps: Sort lines · Text cleaner · Find and replace
