To sort lines, paste your list into the Sort Lines tool and choose A to Z, Z to A, by length, natural number-aware order, or shuffle. Sorting is locale-aware and can ignore case, so accented and mixed-case entries land where you expect.
Follow along with the free Sort Lines, which runs in your browser, or browse more tools in this category.
How to use the Sort Lines
- Paste your list with one item per line.
- Pick a sort order: A to Z, Z to A, by length, natural, or shuffle.
- Turn on case-insensitive sorting if capitals should not affect order.
- Copy the sorted list.
Worked example
Sorted naturally, file2, file10, file1 becomes file1, file2, file10. A plain alphabetical sort would put file10 before file2.
Tips and common mistakes
- Use natural order for anything containing numbers, such as file names or version labels.
- Shuffle is handy for randomizing a list of names or questions.
- Remove duplicates first if you want a clean unique, sorted list.
Frequently asked questions
What is natural sort order?
It compares numbers by value, so 2 comes before 10, unlike plain alphabetical order.
Does it handle accented letters?
Yes. Sorting is locale-aware.
Can I sort by line length?
Yes, shortest to longest or the reverse.