Skip to content
ToolMug

Remove Duplicate Lines

Paste a list and get every line only once. The first occurrence of each line is kept in its original position, and you can see how many duplicates and empty lines were removed.

Runs in your browser — nothing you enter is uploaded

How to use

  1. Paste your list, one item per line.
  2. Choose whether to ignore case, trim spaces and remove empty lines.
  3. Optionally pick a sort order for the result.
  4. Copy or download the cleaned list.

Options explained

Ignore case
Treats Apple, apple and APPLE as the same line. The first spelling found is kept.
Trim spaces
Removes spaces and tabs at the start and end of each line before comparing, so "apple " and "apple" count as duplicates.
Remove empty lines
Drops blank lines, including lines that contain only spaces.

Examples

Email list. Paste addresses collected from several sign-up forms, turn on Ignore case, and get each address once.

Log cleanup. Paste repeated error messages to see the distinct ones, then sort them A → Z.

Frequently asked questions

Which copy of a duplicate is kept?

The first one. Later repeats are removed and the remaining lines stay in their original order unless you choose a sort order.

How many lines can it handle?

Hundreds of thousands of lines are processed instantly in a modern browser.

Can I remove duplicates from an Excel column?

Yes. Copy the column, paste it here, and paste the result back. Each cell becomes one line.

Is my text uploaded?

No. Everything runs in your browser.

Privacy

This tool runs entirely in your browser. Your files and text are processed on your device and are never uploaded to our servers.

Related tools