Skip to content
SUMILORASUMILORA

Sort lines of text

Numbers & text

Paste your lines and choose how to sort them.

Runs in your browser

Nothing is uploaded. The work happens on your own device, so your file or text never reaches us.

About this tool

Natural and language-aware sorting

Alphabetical sorting here is natural: file2 comes before file10, where a plain character sort would put file10 first because 1 is less than 2.

It is also language-aware. Swedish puts å, ä and ö after z; German treats ä as a; Spanish no longer separates ch. Sorting uses the collation rules of the page’s language rather than comparing code points, which is the only way those come out right.

Questions

Why is file10 after file9 here but not in my editor?

This uses natural sorting, which reads runs of digits as numbers. A plain sort compares character by character, so "1" in file10 beats "9" in file9.

Related tools