Sort lines of text
Paste text to sort its lines alphabetically, numerically or by length, in ascending or descending order. Optionally trim whitespace and remove duplicates. The result is stored privately in your account.
No sign-up needed — runs instantly in your browser.
How it works
- 1Paste your text
- 2Choose the sort mode and order, then press Run
- 3Download the sorted text or find it in your files
Frequently asked questions
- How does numeric sorting work?
- Each line is parsed as a number; non-numeric lines are sent to the end.
- Can I remove duplicates while sorting?
- Yes — enable Remove duplicates to keep only the first of each repeated line.
Related tools
Paste text to remove duplicate lines, keeping the first occurrence and the original order. Choose case sensitivity, whitespace trimming and whether blank lines are kept. The result is stored privately in your account.
TextPaste text to count words, characters (with and without spaces), lines, sentences and paragraphs, plus an estimated reading time. The report is stored privately in your account.
TextPaste text and convert it between UPPERCASE, lowercase, Title Case, Sentence case, camelCase, snake_case and kebab-case. The result is stored privately in your account.
TextPaste text and replace a word, phrase or regular-expression match with something else. Choose case sensitivity and whether all matches or just the first are replaced. The result is stored privately in your account.
Text