Sort Lines Alphabetically
Sort all lines of text in alphabetical or reverse alphabetical order.
Sort lines alphabetically, A to Z or Z to A. By default the sort ignores case and uses natural number order, so "item 2" comes before "item 10", and empty lines are removed. Accented letters sort with their base letters using your browser's language rules. Paste a list of names, words, files or tags and copy it back sorted.
Common use cases
- Alphabetise a list of names or words
- Sort tags, keywords or imports
- Put a bibliography or glossary in order
How to use
- Paste the list, one item per line.
- Choose the order and options.
- Copy the sorted list.
FAQ
What is natural order?
Numbers inside text are compared by value, so 2 comes before 10. Plain alphabetical order would put 10 first.
Can I remove duplicates too?
Use the deduplicate lines tool before or after sorting.
Related tools
- Reverse LinesReverse the order of lines in text from last to first.
- Deduplicate LinesRemove duplicate lines from text keeping only unique entries.
- Join LinesCombine multiple lines into a single line with custom separator.
- Remove WhitespaceStrip all whitespace characters including spaces, tabs, and newlines from text.
- Remove PunctuationRemove all punctuation marks from text while keeping letters and numbers.
- Remove Duplicate SpacesReplace multiple consecutive spaces with single spaces throughout text.