Textnify

Sort Lines Alphabetically

Put a list in alphabetical order in one click. Sorting follows the rules of the language you choose, so accented letters land where readers expect them.

Your text stays in this browser tab. Nothing is uploaded, saved or logged.

How the Sort Lines Alphabetically works

Lines are compared with your browser’s locale-aware collation, not by raw character codes. That is why “éclair” sorts next to “eclair” rather than after “zebra”, and why capitals and lowercase letters are mixed naturally. The sorting language matters: Swedish puts ä after z, while German sorts it with a.

Turn on “Sort numbers by value” for natural order, so file2 comes before file10. Without it, digits are compared character by character and file10 comes before file2. Case-sensitive mode places lowercase before uppercase for the same letter.

The sort is stable: lines that compare as equal keep their original relative order. Empty lines sort first unless you remove them.

How to use it

  1. Paste your list, one entry per line.
  2. Pick the order and the language that matches your list.
  3. Copy the sorted list.

Example

Sorted A to Z with English rules and natural number order.

Input

zebra
Éclair
apple
file10
file2
Banana

Result

apple
Banana
Éclair
file2
file10
zebra

Frequently asked questions

Why do accented words sort differently in another language?

Alphabets disagree on where extra letters go. In Swedish, å, ä and ö come after z, while in German ä is treated almost as a. Choose the language of your list in the options.

How do I sort numbers correctly?

Turn on “Sort numbers by value”. For a plain list of numbers this orders 2, 10, 100 rather than 10, 100, 2.

Can I remove duplicates while sorting?

Run Remove Duplicate Lines first or afterwards; sorting places identical lines next to each other, which makes duplicates easy to spot.