Sort lists
Sort lists alphabetically, numerically or randomly.
How to use
Paste a list with one item per line and choose an order: A → Z, Z → A, Numeric or Random. Blank lines are removed, duplicates are kept, and the result appears below with a Copy button. Everything happens in the browser, so a long list does not have to leave your device.
A → Z and Z → A follow the alphabetical rules of the page’s language: accented letters sit next to their plain letter, and capitals do not jump ahead of lowercase words. Alphabetical order is language-dependent: Spanish sorts ñ after n, Swedish puts ä near the end of the alphabet, and German has two accepted orders.
Numeric reads lines that are plain numbers by their value, with a decimal point or comma and an optional minus sign, so 9 comes before 10 and -3 before 1.25. Lines that are not plain numbers follow, in natural order, where the digits inside them count as numbers: item2 before item10. A comma is read as a decimal separator, so 1,500 is sorted as 1.5: write thousands without a separator, as 1500.
Random shuffles the list with the browser’s cryptographic random source, giving every possible order the same chance. That makes it suitable for drawing names or picking a fair order, as long as everyone agrees on the list before the shuffle.
Example
item2, item10 · A → Zitem10 comes first, because text is compared character by character.item2, item10 · Numericitem2 comes first: the digits are read as numbers.10, 9, -3, 1.25 · Numeric-3, 1.25, 9, 10.Ana, Bruno, Carla, Duarte · RandomA new fair order every time you press the button.
Frequently asked questions
Why does item10 sort before item2?
Because text comparison goes character by character: both start with item, then 1 is compared against 2, and 1 wins. The length of the number is never considered. Numeric sorting reads the digits as a value instead, which is what you want for anything numbered.
Why does my spreadsheet sort accents differently?
Because sorting rules belong to a language, not to the alphabet. Where a program sorts by the underlying character number, accented letters land after Z; where it sorts by language rules, they sit next to the unaccented letter. Two tools can both be right and still disagree.
Is the random order really random?
Yes. Each shuffle uses cryptographic randomness and a method in which every order is equally likely, so it can be used for a draw.
Does it remove duplicates?
No, only empty lines. Use the remove duplicates tool first if each item should appear once.