Sort Lines
Sort lines of text alphabetically, numerically, or by length. Runs locally in your browser.
Input
Output
Tip: You can verify in DevTools → Network that nothing is uploaded.
Sorting options
About this Line Sorter
Use this tool to sort lines of text alphabetically, numerically, or by length. Choose ascending or descending order, handle case sensitivity, and clean up your text by removing empty or duplicate lines. Everything runs locally in your browser — nothing you paste is sent to a server.
- Alphabetical — sort by text order
- Numerical — sort by numeric value
- By length — sort by line character count
- Enable Auto to sort as you type
- Trim lines removes leading/trailing whitespace
- Remove duplicates works after sorting
FAQ
No. Sorting happens locally in your browser. Nothing you paste is sent to a server.
Lines with valid numbers are sorted numerically. Non-numeric lines are sorted alphabetically and placed after numeric lines.
When "Remove duplicate lines" is enabled, duplicates are removed after sorting, keeping only the first occurrence of each unique line.
Yes, but extremely large files may be slow depending on your device. The current limit is 5MB.
After the page loads once, it will typically keep working if you go offline (unless you hard refresh with no cache).