Sort Lines
Sort lines of text in any order — alphabetically, by length, numerically or randomly. Results update live.
How to Use Sort Lines
To sort lines of text, paste your content into the left input area. Each line is treated as a separate item to be sorted. Choose your sort order — alphabetically A–Z, reverse Z–A, by line length, or randomly shuffled — and the sorted output appears instantly in the right panel.
Additional options let you sort case-insensitively so that 'apple' and 'Apple' are treated as equal, trim whitespace before sorting, and remove empty lines from the output. Click Copy to copy the sorted result. This is useful for sorting lists of names, URLs, keywords, or any line-delimited data.
Frequently Asked Questions
Does the sort tool handle numbers correctly? expand_more
The tool supports numeric sorting so that '10' comes after '9' rather than between '1' and '2' as it would in a purely alphabetical sort.
Can I sort lines in reverse order? expand_more
Yes. Choose the Z–A or Descending option to sort lines in reverse alphabetical or reverse numeric order.
Does it remove duplicates while sorting? expand_more
You can optionally enable duplicate removal during sorting. This combines the sort and deduplication steps in a single operation.
Is sorting case-sensitive by default? expand_more
By default, sorting is case-sensitive, meaning uppercase letters come before lowercase. You can switch to case-insensitive mode so that letter case is ignored during comparison.
Can I sort by line length? expand_more
Yes. The 'by length' option sorts lines from shortest to longest, or you can reverse it for longest to shortest. This is helpful for formatting or analysing lists by word count.
Related Tools
All Text & Listsarrow_forwardWord Counter
Count words, characters, sentences, reading time and keyword density live.
Case Converter
Switch text between 12 cases: UPPER, lower, camelCase, snake_case and more.
Lorem Ipsum Generator
Generate placeholder text by words, sentences or paragraphs. Copy HTML too.
Duplicate Line Remover
Remove duplicate lines with case-insensitive matching and whitespace trimming.