Skip to content
MC Command Generator

/spreadplayers Command Generator

Beta

Set the centre, how far apart players must land and how far out they can go. The map preview drops the players at random spots that keep the gap.

Describe it — AI writes the command

Type what you want in plain words. The AI fills the form below, so you can see it and change anything. It follows the edition and version you picked.

Checking the AI…

Paste a command— edit it here or move it to another version

Targets land inside a 400 × 400 block square around the centre.

Options
400 blocks
min 20 apart · range ±200
8 targets spread at least 20 blocks apart within 200 blocks of ~ ~. Spots are random each time.

Your command · Java 26.3

34 characters
/spreadplayers ~ ~ 20 200 false @a

Raw editor

How it works

/spreadplayers picks random spots inside a square around the centre (max range in every direction) that are at least the spread distance apart, then teleports the targets onto the highest block there. It avoids lava, water and fire. If the targets don't fit, nobody moves.

Java

spreadplayers ~ ~ 20 200 false @a
spreadplayers 0 0 50 500 true @a

The true/false is respectTeams: with true, teammates land together on one spot. Java 1.16 added under, which lands players on the highest free spot below a height. That stops them landing on the Nether roof:

spreadplayers ~ ~ 10 100 under 100 false @a

Bedrock

Targets come before the optional max height (Bedrock 1.21.20+), and there is no team option. Bedrock also needs the max range to be at least the spread distance + 1.

spreadplayers ~ ~ 20 200 @a
spreadplayers ~ ~ 10 100 @a 100

FAQ

What is the difference between spread distance and max range?

Spread distance is the smallest gap between two targets. Max range is how far from the centre they can land, on both x and z, so the area is a square twice the range wide.

Why does /spreadplayers fail?

Usually the targets can't fit: the range is too small for that many players at that distance. Raise the max range or lower the spread distance. On Bedrock the range must also be at least the distance + 1.

How do I use /spreadplayers in the Nether?

Add a max height so players land below the roof: under 100 on Java 1.16+, or the height after the targets on Bedrock 1.21.20+.

What does respectTeams do?

On Java, true puts every member of a team on the same spot, so teams start together and apart from the other teams. Bedrock has no teams.

Can I spread mobs too?

Yes. Any entity selector works, like @e[type=cow]. Players and mobs are moved the same way.