Random Group Generator
Paste a list of names and split it into random groups — by how many groups you want or by how many people each group holds. The same list and seed always give the same result.
About this tool
The generator shuffles the list you paste and then cuts it into groups, either by the number of groups you want or by how many people each group should hold. The shuffle is a standard Fisher and Yates pass driven by a seeded random number generator, so the order is genuinely mixed rather than merely rotated, and no name is favoured by its position in the list.
The seed is what makes the result repeatable. Most random group tools reshuffle on every reload, which means a set of groups cannot be written down, checked, or reproduced later. Here the seed is shown next to the result and can be typed in, so the same list and the same seed always produce the same groups, and changing the seed is an explicit act rather than something that happens when the page refreshes.
Why the same seed gives the same groups
The shuffle draws from a seeded generator rather than the system random source, so the sequence of choices is fixed by the seed. The same seed replays the same sequence and therefore the same groups.
A generator like this is a deterministic function: given the same starting integer it emits the same stream of numbers, and the shuffle consumes that stream in the same order every time. Feeding the seed text through a hash turns any word or phrase into that starting integer, which is why a seed can be something memorable rather than a long number.
The practical effect is that randomness and reproducibility stop being in tension. The result looks arbitrary — no pattern, no alphabetical order, no one always first — yet it can be written down and regenerated exactly. For a teacher filing groups with a lesson plan, or for anyone who has to justify why the teams came out as they did, that is the property that matters.
Balanced groups versus a leftover group
Splitting by number of groups spreads the remainder across the first groups, so the sizes differ by at most one. Splitting by people per group can leave a final group that is short.
The two modes answer different questions and therefore produce different shapes. Asking for four groups from eleven names yields three groups of three and one of two, because the remainder is distributed rather than pushed to the end. Asking for groups of four from eleven names yields two groups of four and one of three, because the constraint is the group size and the leftover is whatever remains.
Neither is more correct; they match the two ways people describe the task. The tool reports the resulting sizes next to the groups so the shape is visible at a glance, and the names are still listed in full so nothing can quietly fall out of the split.
Names are not de-duplicated: both people called Zhang San belong
Four people, two of them sharing a name, split into two groups gives two groups of two, with the two namesakes landing in different groups. De-duplicating would turn four people into three and make one of them disappear.
Duplicate names are real: two children called the same thing in one class, two colleagues with the same common name. They occupy two rows on a sign-up sheet, so they deserve two places in the draw. This page therefore counts rows rather than distinct names, and does not flag duplicates, because in this context a duplicate is not an error.
If the two really must be told apart, the way is to add a marker yourself, such as a middle initial, rather than let the tool merge them quietly. A tool deciding that two entries are the same person costs somebody their place, which is far worse than showing a repeated name.
One more thing about the randomness: the same seed always produces the same groups. That makes a result checkable and turns reshuffling into a deliberate action, instead of new groups appearing on every refresh.
A random comparator is not a shuffle, and it is measurably unfair
Sorting with Math.random minus 0.5 does not produce equal permutations. With three items the most likely order appears about 37 percent of the time and the least likely about 6 percent.
Measured over 120,000 draws of three items, the shuffle used here returns every one of the six possible orders between 16.4 and 16.8 percent of the time. The comparator trick returns 37.5 percent for 012, 31.1 percent for 210, and roughly 6.3 percent for each of the remaining four.
The cause is that sort assumes a consistent comparator. A random one is not consistent: it can claim a before b, b before c and c before a in the same run. The engine is free to do almost anything with that contradiction, including skipping comparisons, which is why the damage depends on array length and on the engine's algorithm.
It also breaks the seed promise. The same seed must give the same groups, but a comparator-driven sort depends on how many comparisons the engine happened to make, so the result would differ between browsers for the same seed. Fisher-Yates walks the array once and only ever swaps with a random index, which is uniform and reproducible at the same time.
Frequently asked questions
How does the random grouping work?
The list is shuffled with a Fisher and Yates pass, which walks from the end and swaps each position with one chosen at random from those before it. Every ordering is equally likely, so no name systematically ends up at the top or in the first group. The randomness comes from a seeded generator, which means it is reproducible rather than drawn from the system random source.
Can I get exactly the same groups again?
Yes — keep the seed. The same list of names with the same seed always produces the same groups, in the same order. Write the seed down with the result and you can rebuild the groups weeks later. Change the seed and you get a fresh arrangement, which is the honest way to reroll: explicit, repeatable, and visible.
Why is the last group smaller?
That happens in the people-per-group mode when the class size is not an exact multiple of the group size — twenty-three students in groups of four leave a final group of three. It is the expected behaviour of splitting by group size. If you would rather have evenly sized groups, switch to the number-of-groups mode, which spreads the remainder across the first groups instead of leaving one short.
Are duplicate names removed?
No. Two people in a class can share a name, and silently dropping one would lose a student without any warning. Every non-blank line is treated as a person, so a list with the same name twice produces a group containing that name twice, on purpose.
Related tools
Add each graded item weight and score — percent weights or earned-over-possible points — to get the weighted grade so far, with a floor and ceiling for what is not graded yet.
Enter your current grade, the weight of the final, and the grade you want — and see exactly what you need on the final, or that it cannot be reached even with a perfect score.