Sort Lines
Sort text lines alphabetically, numerically, by length, or randomly — ascending or descending order.
About Sort Lines
Sorting lines of text is a fundamental text processing operation used in data preparation, code organization, and list management. This tool sorts text line by line with multiple sorting modes: alphabetical (lexicographic), numerical (treating lines as numbers), by line length, random shuffle, and simple reversal of current order.
The numerical sort is particularly useful for sorting numbered lists, IP addresses, version numbers, and log files with numeric prefixes. It uses a natural sort algorithm that treats numeric sequences within lines as numbers rather than text, so "item10" sorts after "item9" instead of between "item1" and "item2".
Combined with the "Remove duplicates" option, sort lines is a powerful deduplication and normalization tool for building clean vocabulary lists, sorted configuration entries, and unique identifier sets.