Text Tools

Sort Lines

Sort any list of lines alphabetically, in reverse order, numerically, or randomly, in one click. Handles hundreds of thousands of lines instantly, all in your browser.

Alpha, reverse, shuffle, or by length Browser-only Instant result
Lines to sort

Paste lines of text and choose a sort order below.

Sort order
Sorted lines
Download

Processed in your browser; your text is never uploaded

Features

  • Alphabetical (A-Z) and reverse (Z-A) sort
  • Numerical sort for number lists (natural sort order)
  • Random shuffle for list randomisation
  • Case-insensitive sort option
  • Remove blank lines before sorting option
  • Shows line count before and after

How to use it

  1. Paste your list into the input panel.
  2. Select the sort type: A-Z, Z-A, Numerical, or Random.
  3. Sorted list appears instantly in the output panel.
  4. Copy or download the sorted result.

Use cases

  • Alphabetising a list of names or keywords
  • Sorting file paths for comparison or documentation
  • Numerically ordering log line IDs or version numbers
  • Randomising a list of items for a random assignment

Limitations

  • Supports ascending, descending, length ascending, length descending, and random shuffle.
  • Very large text blocks depend on browser memory.
  • Processing happens entirely in the browser tab.
Questions & answers

Frequently asked

What is the difference between alphabetical and numerical sort?

Alphabetical sort compares character by character, so '10' comes before '9'. Numerical sort treats values as numbers, so 9 comes before 10.

Does case matter in alphabetical sort?

By default, uppercase letters sort before lowercase. Enable case-insensitive mode to sort 'apple' and 'Apple' together.