Remove Duplicate Lines
Delete repeated lines from a list, with optional case-insensitive matching.
0
In
0
Out
0
Removed
Unique lines
Paste some lines on the left.
About Remove Duplicate Lines
Merged exports, copied lists and concatenated logs all tend to accumulate repeated lines. Removing them by hand is tedious and error-prone once the list runs past a screenful.
This tool deduplicates instantly while preserving order, optionally ignores case and surrounding whitespace, and can invert the operation to show you exactly which lines were repeated and how often.
How Remove Duplicate Lines works in your browser
Lines are compared in order and the first occurrence of each is kept, so the original sequence survives. Optional normalisation ignores case and surrounding whitespace when deciding whether two lines match.
The inverted mode shows only the lines that were repeated, with a count of how many times each appeared.
When to use it
- Cleaning a merged email or contact list.
- Finding which entries appear more than once in an export.
- Deduplicating log lines before analysing them.
Worked examples
Merge differently capitalized list entries
Settings: Keep unique lines; Ignore case and Ignore surrounding spaces enabled
Input
Apple
apple
Pear
APPLEExpected output
Apple
PearThe comparison key is trimmed and lowercased, but the output keeps the first original spelling and position. The options affect matching, not the formatting of the retained line.
Find recurring entries and their counts
Settings: Show only duplicates; Ignore case enabled
Input
Apple
Pear
apple
AppleExpected output
Apple (3×)A repeated value appears once with its total count. Pear is omitted because it occurs only once. The count suffix is a report, not an unchanged copy of the original data.
Limits and checks before you use the result
- A line is the entire record. This does not deduplicate CSV rows by a selected column, validate email addresses or compare the contents of URLs.
- Ignore surrounding spaces is enabled initially; Ignore case is not. Check these controls before processing identifiers where spaces or capitalization matter.
- Blank lines are kept unless Remove blank lines is enabled. Case folding uses JavaScript lowercasing, not language-specific collation or Unicode normalization.
Frequently asked questions
Is the original order kept?
Yes. The first occurrence of each line stays in place and later duplicates are removed.
Can I ignore case and whitespace?
Yes. Both are options, so "Apple" and " apple " can be treated as the same line.
Can I keep only the duplicates?
Yes, invert the mode to show only the lines that appeared more than once, along with their counts.