Sort Lines

Descending

Ascending
Descending
Numeric sort
Ignore case
Input
Result
10 2 apple banana cherry

This tool sorts the lines of a multi-line text block: alphabetically (case-sensitive or not) or by numeric value when each line starts with a number. Choose ascending or descending order.

Useful for sorting to-do lists, names, domains, product lists, or numbers from a report or log — instead of dragging lines around by hand, paste the list and get a sorted result instantly. Numeric sort avoids the classic problem of alphabetical number sorting, where "10" ends up before "2."

Frequently asked questions

Regular sort compares lines character by character, so "10" ends up before "2." Numeric sort compares lines as numbers: 2, 10, 100 — in the correct order.
In numeric mode, lines without a leading number are pushed to the end of the list, keeping their relative order among themselves.
By default, yes (uppercase sorts before lowercase). Turn on "Ignore case" so Apple and apple sort the same.