Sorts lines alphabetically, numerically or by length.
Sort Lines reorders the lines of any text alphabetically, numerically, or by line length, in ascending or descending order. It's handy for tidying up word lists, log entries, CSV rows, or import statements, and includes an optional case-insensitive mode for alphabetical sorting. Paste your text, pick a sort mode and order, and get the sorted result instantly in your browser.
No. Sorting runs entirely in your browser using JavaScript, and nothing you paste is uploaded or stored on any server. The site is open source so you can verify this yourself.
Numeric mode parses the start of each line as a number; lines that don't begin with a valid number are treated as 0. This means text-only lines will cluster together rather than being ordered alphabetically.
When enabled, alphabetical sorting compares lines without regard to upper or lowercase, so "Apple" and "apple" sort together. It only affects alphabetical mode, not numeric or length sorting.
Lines are split on the newline character (\n). Empty lines are kept as empty strings and sorted along with the rest, so blank lines may move position in the output.
Length mode sorts purely by the number of characters in each line. Lines with the same length keep their original relative order and are not further sorted alphabetically.