Text Line Sorter
Sort lines of text alphabetically, by length, or randomly. Remove duplicates.
Text Sorter Features
Multiple sort modes for organizing text data.
Sort lines A to Z or Z to A.
Sort shortest or longest lines first.
Randomly shuffle line order.
About This Tool
This tool sorts lines of text into order: alphabetical, reverse alphabetical, numerical, or by length. Sorting a list by hand is slow and mistake-prone, and spreadsheet sorting is overkill for a quick list of names, keywords, or references.
Alphabetical sorting follows dictionary order, while numerical sorting reads the numeric value of each line so that 2 comes before 10, which a naive alphabetical sort would reverse. The tool also commonly offers case-insensitive sorting and the option to remove blank lines, so the ordered output is clean.
A subtle but important choice is natural sort order versus plain lexical order. Plain sorting places item10 before item2 because it compares character by character, while natural sorting reads the embedded numbers and orders them the way a person would. For lists of file names, versions, or anything mixing text and numbers, natural order is almost always what you actually want. For lists that mix text and numbers, such as file names or version labels, natural sort order is usually what you want, since it reads the embedded numbers and orders them the way a person would rather than comparing purely character by character.
How to Use It
- Paste your list, one item per line.
- Choose the sort order: alphabetical, reverse, numerical, or by length.
- Copy the sorted list.