Zum Inhalt springen

Zeilen sortieren

Beliebige Liste sortieren: A-Z, Z-A, nach Länge oder zufällig - im Browser.

Läuft in deinem Browser

Liste einfügen, Reihenfolge wählen, sortierte Ausgabe holen. Fünf Reihenfolgen: alphabetisch A-Z, Z-A, nach Länge (kurz zuerst), nach Länge (lang zuerst), zufällig.

So funktioniert's

  1. Paste your text

    One entry per line. Empty lines are kept or dropped per the option.

  2. Pick a sort order

    A-Z, Z-A, by length (short or long), or random.

  3. Copy the sorted list

    Output appears in the right pane. Hit Copy to grab it all.

Was ist das?

A line sorter takes a text input and re-orders its lines by a chosen comparison: lexicographic, length, or random. The interesting choices are around stability (lines with equal keys keep their input order), locale (so 'café' sorts properly), and natural ordering (so 'page-2' beats 'page-10').

Wann verwenden

Organising a list of names, emails, slugs or URLs before sharing or importing. Building an A-Z reference page from a notes dump. Shuffling a playlist or class roster when you need a random order. Putting a CSV's header line aside, then sorting the body, then pasting them back together.

Häufige Fehler

Sorting a CSV with a header row included - the header lands somewhere alphabetical and the file no longer parses. Forgetting that 'page-10' beats 'page-2' in pure-ASCII sort but not in natural sort. And using ascending order to mean 'oldest first' when the lines are dates in YYYY-MM-DD - that's already alphabetical-by-date, so ascending is oldest, descending is newest.

FAQ

Is the sort stable?
Yes. Lines that compare equal keep their relative input order. Important when you're sorting by length and want the original sequence preserved within each length bucket.
Does it handle numbers naturally?
Yes. 'item-2' sorts before 'item-10' using JavaScript's Intl-aware comparison; if you want pure ASCII order ('item-10' first), turn off natural ordering.
What about case?
Case-insensitive by default. Toggle case-sensitive to put all uppercase before lowercase ('A' before 'a').

Mehr in dieser Kategorie