Sort lines Z to A
Puts a list in reverse alphabetical order, so the entry that comes last in a dictionary is first.
| What it does | Puts a list in reverse alphabetical order, so the entry that comes last in a dictionary is first. |
|---|---|
| Exact rule | The comparison is the same as on the A to Z page but run backwards: blank lines are dropped, entries are compared by lower-case form, then by exact text, one Unicode code point at a time. |
| Example text | pear ⏎ Apple ⏎ banana ⏎ apple ⏎ Cherry |
| Example result | pear ⏎ Cherry ⏎ banana ⏎ apple ⏎ Apple |
| Limits | Numbers are compared as text, so 10 still sits next to 1 rather than after 9, and an accented letter lands at the top because it is numbered after z. |
| Where it runs | In your browser: your text is never uploaded, stored or logged. |
Related tools
Remove extra spaces Remove line breaks Remove duplicate lines Sort lines A to Z Reverse text Reverse line order Find and replace Text compare (diff)
All tools in Clean up and compare text
How to use the sort lines Z to A
- Paste one entry per line.
- Read the result from the top: the highest name is first.
- Copy it, or switch to the A to Z page for the usual order.
How it works
The comparison is the same as on the A to Z page but run backwards: blank lines are dropped, entries are compared by lower-case form, then by exact text, one Unicode code point at a time.
Numbers are compared as text, so 10 still sits next to 1 rather than after 9, and an accented letter lands at the top because it is numbered after z.