Sort Lines Alphabetically
Paste a list and sort every line from A to Z or Z to A in one click. Numbers sort by value instead of by character, so "item2" comes before "item10" the way you'd actually expect.
Order
Why This Tool Matters
You've got a list of names, product SKUs, or file names in whatever order they happened to be entered, and you need them alphabetized before importing into a spreadsheet. You're putting together a bibliography or reference list and every entry needs to be in order. You've exported a column from a CSV and the rows came out in random order instead of the sequence you need. Sorting a short list by hand is manageable; sorting hundreds of lines while also handling mixed case and numbers correctly is not. This tool sorts the whole list in one pass, using a natural sort so numbered items land in the right numeric order instead of a naive character sort.
How to Use
- 01
Paste your list
Paste your list into the box above, one item per line.
- 02
Choose sort order
Pick A → Z or Z → A, and adjust the case and blank-line options.
- 03
Sort lines
Click Sort Lines and copy the result.
More Text Tools
Frequently Asked Questions
Does this sort numbers correctly (1, 2, 10) or alphabetically (1, 10, 2)?+−
Correctly. This tool uses a "natural sort" that reads multi-digit numbers as whole values, so a list containing "item1," "item2," and "item10" sorts in that numeric order instead of the lexicographic "item1, item10, item2" you’d get from a naive character-by-character comparison.
Will blank lines mess up the sort order?+−
Not unless you want them to. By default, blank lines are sorted along with everything else and typically land at the start of an A → Z sort. Turn on "Remove empty lines while sorting" if you’d rather they be dropped entirely instead of sorted into the result.
Can I sort in reverse (Z to A) order?+−
Yes — switch the order toggle from "A → Z" to "Z → A" and the result reverses, whether you’re sorting a fresh list or re-sorting one you’ve already run through the tool.
Does capitalization affect how lines are sorted?+−
Only if you turn "Case-insensitive sort" off. With it on (the default), "banana" and "Apple" sort purely by letter, so mixed-case lists read the way you’d expect alphabetically. Turn it off and capital letters sort before lowercase letters, so a list of all-uppercase lines clusters ahead of lowercase ones.