Text Sorter
Paste your text below and sort it line-by-line, alphabetically or numerically.
CleanTextly's Text Sorter reorders any list of lines — alphabetically or numerically, ascending or descending — right in your browser. Paste a list of names, scores, or reference data, pick a sort mode, and the result updates instantly. Duplicate lines are always preserved and nothing you paste is ever uploaded, so it's just as safe for a spreadsheet export as it is for a personal list.
Features
4 Sort Modes
Sort lines Alphabetically (A → Z), Reverse Alphabetically (Z → A), or Numerically in ascending or descending order.
Live Sorting
Output updates instantly as you type, paste, or change the sort mode — there's no button you have to click to see the result.
Stable, Predictable Order
Lines that compare equal keep their original relative order, and duplicate lines are always preserved rather than removed.
Flexible Sorting Options
Optionally remove empty lines, trim whitespace before comparing, or turn on "Case sensitive" sorting.
100% Private
Everything runs locally in your browser. Your text is never uploaded, logged, or stored anywhere.
How to Use
- 1
Paste your text
Add the list or lines you want to sort into the input box.
- 2
Choose a sort mode
Select Alphabetical, Reverse Alphabetical, or Numeric (Ascending or Descending) from the Sort Mode dropdown.
- 3
Adjust the options
Optionally enable "Remove empty lines", "Trim whitespace before sorting", or "Case sensitive".
- 4
Copy or clear
The sorted result appears instantly — copy it with one click, or clear both fields to start over.
Example
Sorting a List Alphabetically
Input
Banana Apple Orange Mango
Output
Apple Banana Mango Orange
Common Use Cases
Alphabetizing Lists
Sort names, product titles, or reference lists into a clean A → Z or Z → A order.
Ranking Numeric Data
Sort scores, prices, or IDs numerically, so values compare correctly instead of as text (where "10" would come before "2").
Preparing Data for Import
Order rows or values before pasting them into a spreadsheet, database, or CMS.
Organizing Reference Material
Sort glossary terms, tags, or keyword lists for easier scanning and lookup.
Frequently Asked Questions
Alphabetical sorting compares lines as text, so "10" would come before "2". Numeric sorting compares them as numbers, so "2" correctly comes before "10".
Lines that aren't valid numbers are moved to the end of the result, keeping their original relative order, while the numeric lines are sorted normally.
No. Duplicate lines are kept exactly as they appear — this tool only reorders lines. If you also want duplicates removed, try the Remove Duplicate Lines tool.
Only if you enable "Case sensitive". By default, sorting ignores case, so "apple" and "Apple" are treated the same for ordering purposes.
Yes. The sort is stable, so when two lines are equal — such as identical duplicate lines — they stay in the same relative order as your original text.
No. Sorting happens entirely in your browser. Your text is never sent to a server or stored.
