Skip to main content
FixLines

Sort lines

Sort lines A to Z, Z to A, by number or by length.

Editor

Ln 1, Col 10 lines0 words0 characters

Sort lines: what it does

Put a list in order in one click: alphabetical A to Z or Z to A, by the first number on each line, or from shortest to longest. You can also shuffle the lines into a random order. Sorting follows the rules of the text language.

Sort lines: how to use it

  1. Paste your list, one item per line.
  2. Choose how to sort or shuffle.
  3. Select Apply and copy the sorted list.

Sort lines: when to use it

  • Alphabetize a list of names, products or keywords for a report or a glossary.
  • Order log lines, prices or scores by the number they contain.
  • Shuffle a list of participants or questions to get a random order.

Sort lines: examples

Sort a list A to Z

Input

pear
apple
cherry
banana

Result

apple
banana
cherry
pear
Sort prices by number

Input

Chair 120
Lamp 35
Desk 480
Mug 9

Result

Mug 9
Lamp 35
Chair 120
Desk 480

Sort lines: questions and answers

Does sorting respect accents and capitals?

Yes. Sorting follows the rules of the text language, so “é” sits next to “e” and capitals do not push words to the end.

How does sorting by number work?

Each line is sorted by the first number found in it, so “item 2” comes before “item 10”.

Can I sort case-insensitively?

Sorting already ignores case for ordering, so “apple” and “Banana” sort as a and b. Lines are not changed, only reordered.

Does sorting remove duplicates?

No. Every line is kept. Run Remove duplicate lines afterwards if you want each entry once.

Is my text sent to a server?

No. Everything runs in your browser on your own device, so your text never leaves it.

Tools people often use together with this one.

More in Sort & deduplicateBrowse all text tools