Mobs in Minecraft spawn within a specific distance range relative to the player:
- Mobs will only spawn at least 24 blocks away from the player. No mobs spawn closer than this minimum distance
- The maximum distance for mobs to spawn naturally is generally up to 128 blocks from the player. Beyond this, mobs will despawn almost immediately
- In Bedrock Edition, mobs spawn within a spherical shell between 24 and 44 blocks away from the player, meaning they can spawn above or below the player as well
- In Java Edition, mobs spawn within a 15×15 chunk area centered on the player, which translates to a horizontal radius of about 128 blocks, but they must be at least 24 blocks away to spawn
- Mobs stop moving if they are more than 32 blocks away from the player and will randomly despawn if not engaged
- For mob grinders and farms, the optimal player position is to be at least 24 blocks away from the spawning area to allow mobs to spawn and move, but within 128 blocks to prevent immediate despawning
In summary, mobs spawn between 24 and 128 blocks away from the player, with a minimum spawn distance of 24 blocks and a maximum effective spawn/despawn radius of about 128 blocks. This applies to both Java and Bedrock editions with some variation in exact spawning shells