Remove Duplicate Lines

Paste a list and strip out every duplicate line, keeping the first occurrence. Choose whether to compare case-sensitively and to ignore empty lines.

Your text is processed locally in your browser and never uploaded.

How to use Remove Duplicate Lines

  1. Paste your list, one item per line.
  2. Choose whether matching should ignore upper/lower case and empty lines.
  3. Press “Remove duplicates”.
  4. Copy the cleaned list, or download it as a text file.

About this tool

Email lists, log files and exports often contain the same line many times. This tool keeps the first occurrence of each line and removes the rest, with options that matter for real-world data: case sensitivity, trimming and empty lines.

Frequently asked questions

Which copy of a duplicate is kept?
The first one, in top-to-bottom order.
Does it trim spaces before comparing?
If you enable “Trim whitespace”, leading and trailing spaces are ignored when comparing lines. Otherwise lines must match exactly.

Related tools