T
DataToolings

Line Sorter

Sort, deduplicate, reverse, and shuffle lines of text. Supports alphabetical, numeric, and length-based sorting with case-insensitive options.

8 lines
8 lines

What Is Line Sorter?

Line Sorter is a text utility that processes multi-line input — sorting alphabetically or numerically, removing duplicates, reversing order, shuffling randomly, and trimming whitespace. It is useful for cleaning up lists, sorting log entries, deduplicating imports, and more.

How to Use

  • Paste your text into the input area (one item per line)
  • Choose a sort mode: alphabetical, numeric, by length, reverse, or shuffle
  • Toggle options: remove duplicates, trim whitespace, ignore empty lines, case-insensitive
  • The output updates instantly — copy it with the Copy button

Features

  • 6 sort modes: A→Z, Z→A, numeric ascending/descending, by length, reverse
  • Random shuffle mode
  • Remove duplicate lines (case-sensitive or case-insensitive)
  • Trim leading/trailing whitespace per line
  • Ignore empty lines option
  • Live line count in input and output

FAQ

Does numeric sort handle decimals?

Yes. Lines are parsed with parseFloat, so values like 3.14 or -10.5 sort correctly. Non-numeric lines are treated as 0.

How does case-insensitive deduplication work?

When case-insensitive mode is on, Apple and apple are treated as duplicates. The first occurrence (in original order) is kept.

Is there a line limit?

No hard limit — processing runs entirely in your browser. Very large inputs (millions of lines) may be slow depending on your device.