Skip to content
MySafeToolbox

Text Sorter

Sort lines alphabetically, naturally (item 2 before item 10), by length, in reverse or shuffled. Remove empty lines and duplicates. Free and fully private.

  • No upload — 100% private
  • Instant, on your device
  • Free, no sign-up
  • Works offline once loaded

How it works

How to use Text Sorter

  1. Paste your lines into the input box.

  2. Pick a sort mode — alphabetical, natural, by length, reverse or shuffle — and a direction.

  3. Optionally remove empty lines, keep unique lines only or make sorting case-sensitive.

  4. Copy or download the sorted list.

Why use it

Why use our Text Sorter tool

Language-aware A–Z

Uses your browser’s collation rules, so accented letters like “É” sort next to “E” rather than after “Z”.

Natural number sort

“item 2” comes before “item 10”, and file9 before file10 — the way people actually count.

Length, reverse, shuffle

Order by character length, flip the current order or shuffle randomly using the Web Crypto API.

Clean-up built in

Drop empty lines, trim spaces and remove duplicates in the same step.

Stays on your device

Sorting runs locally in your browser. Your list is never uploaded.

FAQ

Frequently asked questions

What is natural sort?

Natural sort compares numbers inside text by their value instead of digit by digit. Plain alphabetical order puts “item 10” before “item 2”; natural order gives item 1, item 2, item 10.

How does case-sensitive sorting work?

With case sensitivity off, “apple” and “Apple” are treated as equal. With it on, capitalised words sort just before their lowercase twins, and Unique keeps both versions.

How random is the shuffle?

Each shuffle is seeded from your browser’s cryptographically secure random generator and uses the unbiased Fisher–Yates algorithm. Press “Shuffle again” for a new order.

Why do accented words sort differently than in some spreadsheets?

This tool uses the Unicode collation rules for your browser’s language, which place “é” with “e”. Some apps sort by raw character codes, which pushes accented letters to the end.

Can I sort numbers?

Yes. Choose Natural sort and plain numbers like 3, 25 and 100 are ordered by value, including numbers mixed with words.