Sort Lines Alphabetically

Sort text lines alphabetically, numerically, or in reverse order. Free online line sorting tool with multiple sorting options.

0 characters0 words
Output will appear here...

Related Tools

The line sorter arranges your text lines in alphabetical, reverse alphabetical, or numeric order. It supports case-insensitive sorting and can detect numeric values at the start of lines for proper numerical ordering.

This tool is useful for organizing lists, sorting data exports, alphabetizing names or items, and preparing ordered content. Whether you need to sort a grocery list, a list of names, or numbered data, this tool handles it with flexible options.

All sorting happens in your browser — your text is never sent to any server.

How to Use Sort Lines Alphabetically

  1. 1Paste your lines of text into the input area.
  2. 2Choose ascending or descending order from the dropdown.
  3. 3Optionally enable case-insensitive or numeric sorting.
  4. 4Click the Copy button to copy the sorted result.

Frequently Asked Questions

How does alphabetical sorting work?
Lines are compared character by character using Unicode code point values. By default, uppercase letters sort before lowercase (A < a). Enable case-insensitive mode to ignore capitalization differences.
What does numeric sort do?
Numeric sort parses the leading number from each line and sorts by that value instead of alphabetically. This means '2' sorts before '10' (unlike alphabetical sorting where '10' comes before '2').
Can I sort in reverse order?
Yes. Select 'Descending (Z-A)' from the Order dropdown to sort lines from Z to A (or highest to lowest for numeric sort).
How are blank lines and lines with leading whitespace handled?
Blank lines are sorted to the top in ascending order since empty strings come before any character. Lines with leading whitespace are sorted based on the space or tab characters, which come before letters in Unicode order. Trim whitespace first if you want to sort purely by text content.