Sort & Deduplicate Lines

Paste any list — one item per line — and sort it alphabetically, remove duplicates, and clean up blank lines and stray whitespace, all at once.

0 lines

How to use

Paste your list and toggle the options you need: sort A→Z or Z→A, remove duplicate lines, trim extra whitespace from each line, and drop blank lines. All changes apply live as you toggle them, so you can see the effect immediately.

Common uses: cleaning up an email list before a mail merge, deduplicating a list of URLs or usernames pulled from multiple sources, alphabetizing a list of names for a document, or tidying up a CSV column pasted as plain text.

FAQ

How does case-insensitive sorting and deduplication work?

With case-insensitive mode on, "Apple" and "apple" are treated as the same word for both sorting order and duplicate detection — turn it off if you need strict case-sensitive comparison instead (so "Apple" and "apple" are kept as separate distinct lines).

Which duplicate is kept when removing duplicates?

The first occurrence in your original list is kept; later repeats are dropped. Combine with sorting if you want the kept copy to end up in a specific position afterward.

Does trimming whitespace change the content of each line, or just the edges?

Only the edges — leading and trailing spaces or tabs are removed from each line, while spacing in the middle of a line is left untouched.

Is my list uploaded anywhere?

No — sorting, deduplication and cleanup all run in JavaScript directly in your browser. Nothing you paste here is sent to a server, which makes this safe for internal lists, contacts, or other non-public data.

More tools