Sort Lines
Sort a list of lines alphabetically, by length, or numerically, with options for case sensitivity and dropping empty lines. Tidy a list or order numbers.
How to use
- Paste your list into the box.
- Choose the order, and whether case matters.
- Copy the sorted list.
Sort lines orders a plain list without changing the lines themselves. Alphabetical and length sorting tidy a list, while numeric sorting is what makes a list of numbers or identifiers come out in the right order.
Paste or type something above.
Questions about sort lines
- Why did my numbers sort as text?
- Numeric order is only used when every line is a number, so a line that is not a number makes the list fall back to text order.
- Is the sort case sensitive by default?
- No, so a and A are treated as the same starting letter, which matches how people read a list.
- Does it trim whitespace first?
- No, lines are compared as written. Trim them first with the extra spaces remover if they carry stray spaces.
Related tools
- Remove Duplicate Lines Remove duplicate lines from a list and keep only the first occurrence of each one, with op...
- Remove Extra Spaces Collapse multiple spaces and tabs into a single space and trim the ends of every line, whi...
- Text Cleaner Strip hidden and invisible characters, normalise line endings and tabs, collapse blank lin...