Sort Text Lines

Put any list in order — A to Z, by number, by length or reversed — and strip the duplicates while you are there. Nothing is uploaded.

Sorted
0Lines in
0Lines out
0Duplicates


          

How to use it

  1. Paste your list into the box on the left, one item per line.
  2. Pick how to sort it. A to Z covers most lists.
  3. The sorted list appears instantly — there is no button to press.
  4. Press Copy result, or download it as a .txt file.

Natural sorting, and why it matters

Most sorters compare text one character at a time, which is why they put item10 before item2 — the character 1 comes before 2, and the sorter never notices that these are numbers. This tool uses your browser's natural sort, so numbered lists, version strings and file names come out in the order a human expects.

If your lines are actual measurements — prices, weights, scores — choose one of the Number options instead. That reads the first number on each line and sorts by its value, so 9 kg lands before 80 kg, and negative numbers and decimals are handled properly. Lines with no number in them are pushed to the bottom rather than scattered through the middle.

Frequently asked questions

Why does item 10 come before item 2 in some sorters?

Because a plain alphabetical sort compares one character at a time, and the character 1 comes before 2. This tool uses natural sorting, so item2 correctly lands before item10 without you doing anything.

Can it sort numbers properly, including decimals and minus signs?

Yes. Choose one of the Number options. It reads the first number it finds on each line, so 12.5 kg and -3 degrees both sort correctly. Lines with no number at all are pushed to the bottom.

Does sorting change my capitalisation or spelling?

No. Lines are only reordered, never rewritten. Ignore case changes how lines are compared while sorting, not what comes out.

Is my text sent anywhere?

No. The sorting happens in JavaScript inside your own browser. Nothing is uploaded and nothing is saved — close the tab and the text is gone.

Related tools