Remove Duplicate Lines
Delete repeated lines from a list, keeping the first occurrence of each in its original order.
Processed in your browser. Nothing you enter is uploaded.
The first occurrence of each line is kept, in its original order.
How to use it
- Paste your list with one item per line.
- Choose whether matching is case sensitive, whether surrounding spaces are ignored, and what to do with blank lines.
- Read the cleaned list and the number of lines removed.
- Copy it or download it as a text file.
Example
- A short list
- Input:apple, banana, apple (one per line)
- Result:apple, banana (one per line)
What does Remove Duplicate Lines do?
Remove Duplicate Lines deletes repeated lines from a list and keeps the first occurrence of each in its original order.
How does Remove Duplicate Lines work?
Lines are compared with a Set, the first occurrence wins, and the line endings you used are preserved. The comparison runs in your browser.
Is my data uploaded?
No. Your list is processed in your browser and is never sent anywhere.
Which formats and inputs does Remove Duplicate Lines support?
Inputs: Multi-line text with one item per line; Options for case sensitivity, surrounding spaces and blank lines. Output: The cleaned list and the number of lines removed.
What are the limits and limitations of Remove Duplicate Lines?
Limits: maximum text length 5,000,000 characters; tested with 20,000 lines (about 1 MB). Blank lines are kept by default and are never treated as duplicates.
More questions
Which copy of a duplicate is kept?
The first one. Order is preserved.
Related tools
- Case ConverterConvert text to UPPERCASE, lowercase, Title Case, Sentence case, camelCase, snake_case, kebab-case and more.
- Word CounterCount words, characters, sentences, paragraphs and reading time as you type. Runs in your browser.
- Character CounterCount characters with and without spaces. The primary count is grapheme clusters, so emoji count as one.