Blog
Text tools

Shuffle the lines of a list randomly

Paste your list with one item per line, and the lines come back in a random new order — every item stays exactly as it was, only the order changes. Click "Shuffle again" for a fresh random order without retyping anything.

Result

Lines shuffled —

All calculations run locally in your browser: parsing, chart, export. Disconnect the network and the page keeps working.

Facts and limits of this method

Algorithm Fisher–Yates shuffle — every possible ordering is equally likely
What changes Only line order; the text of each line is untouched
Randomness source Your browser's Math.random(), reseeded on every shuffle
Repeat runs Click "Shuffle again" for a new random order from the same input
Empty lines Treated as ordinary items and can end up anywhere, including first or last
Duplicates Kept as-is; identical lines can still land next to each other by chance

When it misleads you

How it is calculated

The text is split into lines, and the list of lines is copied so the original order in the box isn't touched until you decide to keep the result.

A Fisher–Yates shuffle then walks the copy from the last item to the second one, swapping each with a random earlier item pulled by Math.random() — this is the standard algorithm for a shuffle where every permutation is equally likely.

Unlike naive approaches (like sorting by a random key), Fisher–Yates has no bias toward any particular ordering, which matters if you're using this for anything resembling a fair draw.

"Shuffle again" re-runs the exact same algorithm on the current input without needing you to touch the text box, so you can keep rerolling until you like the order.

Questions and answers

Is the shuffle truly random?

It uses the Fisher–Yates algorithm, which is mathematically unbiased — every possible order is equally likely. The underlying randomness comes from your browser's Math.random(), which is good enough for everyday use but not for high-stakes draws.

Can I get the same shuffle twice?

Not intentionally — every click of "Shuffle again" draws fresh randomness. If you need a reproducible order, this isn't the right tool.

Does it remove duplicate or blank lines?

No, it only reorders. Use the Duplicate Line Remover first if you want duplicates gone before shuffling.

What if I only have one line?

A single line has nowhere else to go, so the result is identical to the input — that's still a correctly "shuffled" list of one.

Is my list uploaded anywhere?

No. The shuffle runs entirely in your browser; nothing is sent to a server.

Related tools

All tools