/ban
Bans a player from the server. Banned players cannot connect until unbanned.
Syntax
/ban <targets> [<reason>]Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| targets | game_profile | Required | The player to ban. |
| reason | message | Optional | The reason for the ban, displayed to the banned player. |
Examples
/ban Steve GriefingBans Steve from the server with the reason "Griefing".
/ban Griefer123Bans the player Griefer123 with no specific reason.
Common Mistakes
- Using /ban instead of /ban-ip, players can rejoin with an alternate account unless IP-banned.
- Forgetting to use /pardon to unban, banned-players.json must be modified or /pardon used.
Notes
Bans persist across server restarts. Use /pardon to unban. For IP-based bans, use /ban-ip. The ban list is stored in banned-players.json.
Related Commands
Need a Minecraft server?
Try these commands on Astroworld or host your own server.
Try Astroworld Hosting