Skip to content
TabKiwiTabKiwi

Sort Lines

Sort lines alphabetically, naturally (item 2 before item 10) or by length, ascending or descending.

TextRuns in your browser. Your files never leave this device.
Loading tool…

About this tool

Paste any list and sort it A to Z, Z to A, or by line length. Natural sorting understands numbers inside text, so "chapter 2" comes before "chapter 10" instead of after it. You can also drop duplicates and blank lines in the same step, all without leaving your browser.

How to use Sort Lines

  1. Paste the lines you want to sort.
  2. Pick natural, alphabetical or length order and the direction.
  3. Optionally remove duplicates or blank lines, then copy the result.

Frequently asked questions

What is natural sorting?

Natural sorting compares numbers inside text by their value rather than digit by digit. Plain alphabetical sorting would put "file10" before "file2"; natural sorting puts file2 first.

How are accented letters sorted?

With case ignored, sorting uses your browser's language-aware comparison, so é sorts next to e. With case-sensitive alphabetical sorting, strict character-code order is used.

Is my text uploaded?

No. The text is processed by JavaScript in this browser tab and never sent to a server.

More Text tools

View all 60 →