Sort Lines
Sort lines alphabetically, numerically, by length, or shuffle them at random.
How to use Sort Lines
- 1Paste your lines.
- 2Choose a sort method and direction.
- 3Turn on natural sorting if your lines contain numbers.
- 4Copy the sorted result.
How it works
Alphabetical sorting uses your browser's locale-aware comparison, which orders accented characters the way the language expects — so 'é' sorts next to 'e' rather than after 'z', which is what a plain byte comparison would do.
Natural sorting is the option most people actually want when their lines contain numbers. A plain alphabetical sort puts item10 before item2, because it compares character by character and '1' comes before '2'. Natural sorting reads runs of digits as numbers, giving item2, item10, item100 — the order a human would use.
The random option uses a Fisher-Yates shuffle driven by cryptographic randomness, which produces a genuinely uniform permutation. Sorting by a random key, the common shortcut, does not.
Your text is processed by JavaScript running in this page and is never sent over the network. That matters when you are pasting a draft, a client brief, meeting notes or anything else you would rather not hand to a server.