Menu

Random Name Picker

Paste your list with one name or item per line and the picker draws one at random, or as many as you ask for, with every line equally likely. Press Pick again for a fresh draw.

0 words 0 characters 0 lines

Continue with this text: Shuffle the whole listRemove duplicates firstSort lines

Your text stays in your browser: nothing is uploaded or stored on a server.

How to pick a random name

  1. Paste or type your list in the box, one name or item per line. Open file loads a .txt or .csv file, and Example fills in eight sample names.
  2. Set How many to pick. It starts at 1; enter 3 to pick three winners, a team of five, or a reading order for the whole group.
  3. Leave Allow the same line twice unticked for a draw without repeats.
  4. The result appears in the Picked box as soon as the list is there, with a note such as “3 of 8 picked”.
  5. Press Pick again for a new draw, then Copy or Download .txt to keep it.

A new draw also happens whenever you edit the list or change an option, so the result never refers to an old version of the list.

The options

Option Default What it does
How many to pick 1 The number of lines to draw. From 1 to 10,000. A larger number typed in is capped at 10,000, and the note says so: “10,000 of 8 picked (at most 10,000 at a time)”. Blank, 0 or a negative number counts as 1, and decimals are rounded down.
Allow the same line twice Off Off: each line comes out at most once, and asking for more lines than the list has returns the whole list in random order. On: each pick is drawn from the full list, so a line can come out again and you can pick more lines than the list holds.
Ignore empty lines On Skips blank lines and lines that contain only spaces, and trims spaces from the start and end of each line. Off: every line counts exactly as typed, blank ones included.

The picks are listed in the order they were drawn, so the first line is the first name out of the hat. That makes the tool usable for ranked results (first, second and third prize) or a random speaking order. To put the winners in alphabetical order afterwards, send them to Sort lines.

How the draw works

The picker splits your text into lines at every line break (Windows, Mac and Unix line endings all work). Without repeats, it shuffles the lines with the Fisher-Yates method, which makes every order equally likely, and keeps the first lines of the shuffled list. With repeats, it draws a line from the whole list for every pick.

The random numbers come from the browser’s Web Crypto API. MDN describes crypto.getRandomValues() as a source of “cryptographically strong random values”, suitable for cryptographic purposes, while MDN warns that Math.random() does not provide cryptographically secure numbers. For a classroom draw either would do; for a prize draw the stronger source is the better choice.

A quick check with the eight example names and 80,000 single draws gave each name between 9,878 and 10,085 picks, close to the expected 10,000 (one in eight).

Rules and edge cases

  • Duplicates count twice. The picker compares nothing: a name that appears on two lines has twice the chance of a name on one line. With the list Ann, Ann, Bob, Ann came out in about two of every three draws. If each person should have one chance, run the list through Remove duplicate lines first; if extra entries are meant to give extra chances, keep them.
  • Spaces. With Ignore empty lines on, Bob is picked as Bob. With it off, the spaces stay and a line of spaces can be picked.
  • A trailing line break. A list copied from a spreadsheet or another document can end with a line break, which leaves an empty last line. With Ignore empty lines off, that empty line is part of the draw, so keep the option on unless blank lines mean something.
  • Emoji, accents and other scripts. A line is picked whole, so 🎉 Prize, Zoë and 東京 come out unchanged.
  • Commas. Names separated by commas on one line are one line. Use the comma separator to put them one per line first.
  • The count note. “5 of 8 picked” compares the picks with the lines in the draw. With repeats allowed, you can see a note such as “20 of 8 picked”.

Worked examples

With the example list of eight names, How many to pick set to 3 and repeats off, one run gave:

Diana
George
Ben

Every run gives a different result. The same list with How many to pick set to 20 and repeats off returns all eight names in random order, because a name cannot come out twice. With repeats on, it returns 20 names, some of them several times.

A list with blank lines and extra spaces:

Ann

  Bob  
   
Cy
Ignore empty lines Lines in the draw One draw of 10
On 3 Bob, Cy, Ann
Off 6 (including the blank lines and the empty line after Cy) Cy, Bob , , (empty), (empty), Ann

When people use it

  • Teachers calling on a student, picking who presents first, or choosing a “student of the day” from a class list.
  • Giveaways and raffles on social media: paste the entrants, remove duplicates if each person may enter once, and pick one winner per prize.
  • Teams and meetings: choosing who takes notes, who runs the next stand-up, or a random order for presentations. To split a whole group into teams, use the text splitter after a shuffle.
  • Writing and improv prompts: keep a list of prompts, first lines or scene suggestions and draw one at a time.
  • Testing and sampling: pull a few random rows from a list of URLs, product IDs or survey answers to check by hand.
  • Everyday decisions: where to eat, which film to watch, which task to start with.

Questions

Is the random name picker really random?

It uses your browser's Web Crypto API (crypto.getRandomValues), the source of random numbers browsers provide for security work, instead of the simpler Math.random. Every line in the list has the same chance, and each draw is independent of the one before.

Can the same name be picked twice?

Not by default. When you pick several, each line can come out at most once. Tick Allow the same line twice to draw every pick from the full list, like rolling a die again. A name typed twice in the list is two lines, though, so it can come out twice even without that option; run the list through Remove duplicate lines first.

Is there a spinning wheel?

No. The page shows the result straight away instead of an animation. A wheel with equal slices gives each name the same chance as this picker, so the outcome is the same; only the show is missing.

How do I pick a winner for a giveaway?

Export or copy the entrants' names into the box, one per line, remove duplicate entries if each person may only enter once, set How many to pick to the number of prizes and copy or download the result. Take a screenshot of the list and the result if you need to show how the winner was chosen.

Does the picker save or upload my list?

No. The draw runs in your browser and nothing is sent to a server. The text is kept in this browser tab so it is still there if you open another tool, and it disappears when you close the tab.

Why did the result change when I edited the list?

The picker draws again whenever the list or an option changes, so a pick always matches the current list. Copy the result before you edit anything if you need to keep it.

How do I pick a random line in Excel?

With the names in A1:A8, the formula =INDEX(A1:A8, RANDBETWEEN(1, 8)) returns a random one. Excel calculates a new number every time the worksheet recalculates, so copy the cell and paste it as a value to keep the result.