A sorted list is easier to scan, easier to deduplicate, and easier to diff against another list. Sorting is also the quickest way to spot outliers — the shortest and longest entries, or values far outside the expected numeric range, end up at the ends.
How to use the Sort Lines
- Paste your list, one item per line
- Choose a sort: alphabetical, reverse, numeric or by length
- Copy the sorted result
Alphabetical is not the same as numeric
Sorting numbers alphabetically produces the classic wrong answer:
1
10
100
2
20
3This is correct alphabetical order — character by character, '1' sorts before '2', so anything starting with 1 comes first regardless of magnitude. Numeric sort reads each line as a number and orders by value, giving 1, 2, 3, 10, 20, 100.
Use numeric sort for anything measured: prices, IDs, counts, version parts, timestamps.
Sorting by length
Less obvious but genuinely useful. Sorting by line length surfaces the extremes immediately — the truncated entries, the one row with a pasted paragraph in it, the keyword that is far longer than the rest.
It is a fast way to sanity-check exported data before importing it somewhere that enforces field limits.
Frequently asked questions
Why are my numbers in the wrong order?
You are using alphabetical sort on numeric data. Alphabetically, 10 comes before 2 because the character '1' precedes '2'. Switch to numeric sort.
How are uppercase and lowercase handled?
Sorting uses locale-aware comparison, so 'apple' and 'Apple' sort adjacently rather than uppercase letters all sorting before lowercase as they would in raw ASCII order.
Does sorting remove duplicates?
No, duplicates are kept and end up adjacent. Use the Remove Duplicate Lines tool first if you want them gone.
Are blank lines preserved?
Blank lines are treated as empty entries and group together. Remove them beforehand if they are not meaningful data.