Sort

Text Sorter

Details

How to use Text Sorter

What the tool does, how to run it, and what to expect from the result.

How the sort compares lines

The text is split on line breaks, blank and whitespace-only lines are discarded, and the rest are sorted with a locale-aware comparison in your browser language. Two settings on that comparison shape the result, and both are worth knowing.

The comparison ignores case and accents. Apple, apple, and APPLE are treated as identical for ordering purposes, and resume and résumé sort together rather than resume coming first because of where the accented character sits in the character table. That is almost always what people want from an alphabetical list, and it is not what a naive sort gives you.

Numbers inside the text are compared as numbers. That means item2, item10, item20 sorts in that order rather than item10, item2, item20. It is the same behavior a file manager uses, and it is the reason version strings and numbered items come out sensibly.

  • Paste one item per line
  • The sorted list appears immediately
  • Blank lines are dropped
  • Press Copy result

Ascending only, and what to do about it

The sort runs A to Z and there is no descending option, no reverse toggle, and no button to flip it. To get Z to A, sort here and then paste the result into Reverse List, which flips the line order. The two steps together give you a descending sort in about five seconds.

There is also no shuffle, no sort by line length, no sort by the second word, and no sort by a column. This tool does one comparison in one direction.

Duplicates are kept. If the same item appears three times it appears three times in the output, sitting next to itself. Run the result through Remove Duplicate Lines if you want one of each, which is easier after the sort than before it since duplicates are now adjacent and easy to spot by eye.

The whitespace trap

Leading whitespace is preserved on every surviving line, and it is part of the comparison. A line that starts with two spaces sorts differently from the same line without them, which means an indented list can come out in an order that looks wrong.

If your list was copied out of a document or a code block and some lines carry indentation, strip the leading spaces before sorting. Otherwise the indented items cluster together at one end regardless of their actual text.

One more nuance: the comparison uses your browser language. Alphabetical order is not the same in every language, so the same list can sort slightly differently on a machine set to a different locale. It only shows up with accented characters and language-specific letters, but it is real.

Tips

Getting a better result out of Text Sorter

Specific settings and thresholds, not general advice.

  • Sort here and then run Reverse List for a Z to A ordering. There is no descending option in this tool.
  • Strip leading spaces before sorting. Indentation is preserved and it participates in the comparison, which throws indented lines out of place.
  • Sort before deduplicating. Duplicates end up adjacent after the sort, which makes them obvious even before you run a dedupe pass.
  • The natural number ordering means version strings and numbered items come out right without padding them with zeros first.
  • Case is ignored for ordering but preserved in the output, so your original capitalization comes back unchanged.
Limits

What Text Sorter does not do

The honest boundary, so you do not lose time finding it yourself.

  • Ascending order only. There is no descending or reverse option.
  • It does not remove duplicates, shuffle, or sort by line length.
  • Leading whitespace is preserved and affects the ordering.
  • The comparison follows your browser language, so results can differ slightly across locales.
At a glance

Who Text Sorter is for

A quick way to understand who this helps, what it solves, and where it connects next.

Best fit

Writers, students, editors, marketers, and developers working with text.

Ideal for

Quick, private text work without installing an app or trusting a server with your content.

FAQ

Common questions

Short answers for the questions people usually have before trying a utility like this.

Is the text sorter free?

Yes. It is free, requires no account, and runs entirely in your browser with no network requests at all.

Can I sort in reverse, Z to A?

Not directly. Sort here, then paste the result into Reverse List to flip the line order. That gives you a descending sort in two steps.

Is the sort case-sensitive?

No. Case is ignored when comparing, so Apple and apple sort together. Your original capitalization is preserved in the output.

How does it handle numbers in the text?

As numbers. item2 sorts before item10, the way a file manager orders files, rather than the character-by-character order that would put item10 first.

Does it remove duplicate lines?

No. Duplicates are kept and end up adjacent after the sort. Use Remove Duplicate Lines afterward if you want a unique list.

What happens to blank lines?

They are dropped, along with lines that contain only spaces or tabs.

Why did my indented lines sort oddly?

Leading whitespace is preserved and counted in the comparison, so indented lines cluster separately. Strip the indentation before sorting.

Does my list get uploaded?

No. The sort happens in your browser. Nothing is sent to a server and the tool makes no network requests, so it works offline.

Does it handle accented characters correctly?

Yes. The comparison is accent-insensitive, so resume and résumé sort together instead of being separated by where the accented letter falls in the character table.

Can I sort by something other than the whole line?

No. There is no column selection, no sort by second word, and no sort by length. The whole line is the sort key.

Recommendations

You Might Also Like

Nearby tools from the catalog that fit the same job or workflow.

Cleanor app

Do it all on your device

Cleanor puts these tools in one app: compress and convert images, video, and audio, work with PDFs, and scan text right on your device. Plus free up storage and clear inbox clutter with Email Cleaner. Start with a free trial.

  • iPhone
  • Android
  • Macsoon
  • Windowssoon