Free Online Sort Lines Tool

Sorting lines reorders the lines in your input alphabetically or numerically, in ascending or descending order.

Your data is processed entirely in your browser and never sent to any server.

Instant results 100% private No signup needed

How to Use This Text Tool

  1. Paste your list into the input field, one item per line.
  2. Choose Alphabetical or Numeric sort.
  3. Toggle ascending or descending and case sensitivity to taste.
  4. Click Copy to grab the sorted result.

What Is a Sort Lines?

Sorting a pasted list is easy in a spreadsheet, easy on the command line (`sort`), and surprisingly awkward in most text editors. Pasting into a dedicated tool is faster than either when you do not want to leave the browser or open a terminal.

The sorter supports alphabetical sort (case-sensitive or case-insensitive), numeric sort that handles negative numbers and decimals, and reverse order. The sort is stable: equal lines retain their relative order, which keeps ordered data with duplicate keys predictable.

Common uses include alphabetising a contact list, ordering log lines by ID, sorting CSV column values before a diff, and arranging a glossary.

Frequently Asked Questions

Is sorting case-sensitive?
By default, sorting can be case-sensitive (capitals first) or case-insensitive. Case-insensitive is usually better for word lists.
Can I sort by something other than the whole line?
Basic tools sort by the full line. For column-based sorting (e.g., by second word), you'd need a CSV/table tool or spreadsheet.
What about numbers?
Alphabetical sort treats numbers as text ('10' comes before '2'). For numeric sort, use a tool that supports natural/numbers-first sorting.

Published by the WeGotEveryTool team. We build and test every tool in-house and update pages when the underlying spec, formula, or recommendation changes.

Reviewed: May 2026. Disclaimer: this tool is provided as-is for general informational use. For decisions with material consequences (medical, legal, financial, security) verify results against a qualified professional source.

Related Text Tools