Text Sorter

Sort lines alphabetically ascending or descending with optional case-insensitive order, numeric sort, and duplicate removal.

Files and content are processed locally in your browser and are not uploaded to our server.

About this tool

Sort multi-line lists alphabetically or numerically. Choose ascending or descending order, ignore case for case-insensitive sorting, treat lines as numbers when appropriate, and optionally remove duplicates after sorting.

How to use

  1. Alphabetical ascending and descending sort
  2. Case-sensitive or case-insensitive mode
  3. Numeric line sorting when values are numbers
  4. Optional dedupe after sort
  5. Keep or remove leading and trailing spaces on each line
  6. Paste lines: Enter one entry per line or import a text file.
  7. Configure sort: Pick direction, case sensitivity, and numeric mode.
  8. Sort and copy: Run Sort and copy the ordered list.

Examples

Limitations

FAQ

How does numeric sort work?
When enabled, lines that parse as numbers are ordered by value instead of lexicographic string order.
Will blank lines be sorted to the top?
Empty lines are kept unless you remove them in a separate cleaning step.
Can I sort Unicode text?
Yes. Sorting uses JavaScript localeCompare with your browser locale.