Skip to content
Minecraft

Minecraft Server Commands — Full List (Java, 2026)

9 min read Updated 10 August 2026 ESAGAMES Team

Minecraft server commands let you manage players, change the world and run admin tasks from the console or in-game. Here's the full list that matters for a Java server, grouped by what you're doing — with the exact syntax. Most need operator (op) permission.

Console vs in-game

From the server console, type commands without the leading slash. In-game, you need operator status (/op yourname from the console) and you type them with the slash. Most admin commands require op.

Players & admin

CommandWhat it does
/op <player>Grant operator (admin) status.
/deop <player>Remove operator status.
/kick <player> [reason]Kick a player from the server.
/ban <player> [reason]Ban a player by name.
/ban-ip <player|ip>Ban by IP address.
/pardon <player>Unban a player.
/whitelist add|remove <player>Manage the whitelist (with /whitelist on to enforce it).
/listList connected players.

Gamemode & difficulty

CommandWhat it does
/gamemode <survival|creative|adventure|spectator> [player]Set a player's game mode.
/defaultgamemode <mode>Set the mode new players join in.
/difficulty <peaceful|easy|normal|hard>Set the world difficulty.
/gamerule <rule> <value>Change a game rule (see below).

Useful game rules

Game ruleWhat it does
/gamerule keepInventory trueKeep items and XP when you die.
/gamerule doDaylightCycle falseFreeze the time of day.
/gamerule doWeatherCycle falseFreeze the weather.
/gamerule mobGriefing falseStop mobs changing blocks (creepers, endermen).
/gamerule doMobSpawning falseStop natural mob spawning.
/gamerule randomTickSpeed <n>Crop/leaf growth speed (default 3).

World, time & weather

CommandWhat it does
/time set <day|night|noon|midnight|number>Set the time of day.
/weather <clear|rain|thunder> [seconds]Set the weather.
/setworldspawn [x y z]Set the world spawn point.
/spawnpoint [player] [x y z]Set a player's personal spawn.
/seedShow the world seed.
/worldborder set <size>Set the world border diameter.

Items, teleport & players

CommandWhat it does
/give <player> <item> [count]Give an item.
/clear [player] [item]Clear a player's inventory (or one item).
/tp <player> <target> / /teleportTeleport a player to another (or to coords).
/effect give <player> <effect> [seconds] [amplifier]Apply a status effect.
/enchant <player> <enchant> [level]Enchant the held item.
/experience add <player> <amount> [points|levels]Give XP.
/kill [target]Kill an entity or player.

Server management & messaging

CommandWhat it does
/save-allForce-save the world now.
/save-off / /save-onDisable / enable auto-save (for backups).
/stopCleanly stop the server (console).
/say <message>Broadcast a message to everyone.
/tell <player> <message>Send a private message.
/title <player> title <json>Show a large on-screen title.
The /execute command

/execute is the most powerful command in Minecraft — it runs another command as, at, or conditional on something else. It's how command blocks and datapacks do advanced logic. Worth learning once you're comfortable with the basics above.

Related Minecraft guides

New to running a server? See how to make a Minecraft server, tune it with best settings to reduce lag, and read server.properties explained. To make yourself admin, see how to op yourself.

Minecraft hosting with console & RCON

Our Minecraft hosting gives you a live console, RCON and a full panel — run these commands and manage your server the easy way.

Minecraft hosting
FAQ

Frequently asked questions

How do I run commands on a Minecraft server?

From the server console, type them without the leading slash. In-game, you need operator status (run /op yourname from the console first) and you type them with the slash. Most admin commands require op.

How do I make myself admin on a Minecraft server?

Run /op yourname from the server console. That grants operator status, letting you run admin commands like /gamemode, /give and /kick in-game. Use /deop to remove it.

How do I keep my items when I die in Minecraft?

Run /gamerule keepInventory true. Players keep their items and XP on death from then on. Set it to false to return to normal.

How do I change the time or weather on a Minecraft server?

/time set day (or night/noon/midnight or a number) sets the time; /weather clear (or rain/thunder) sets the weather. Add /gamerule doDaylightCycle false or doWeatherCycle false to freeze them.

How do I give someone items or op in-game?

With op status, use /give [count] for items and /op to make someone an operator. Both need you to be an operator (or run them from the console) first.

Do Minecraft server commands work the same on Bedrock?

Most core commands are similar, but some gamerule names and syntax differ between Java and Bedrock (for example keepInventory casing). This list is for Java 1.21; check Bedrock docs for its exact spellings.

Further reading

Go deeper on this

Guides and explainers that pair with this fix — from our guides and blog.

Knowledge base

Related articles

Skip the troubleshooting

Managed, protected hosting in Frankfurt — we handle the Linux, the network and the DDoS so you don't have to.

Payments Secure checkout with cards, banking apps and digital wallets.

Choose the payment flow that fits your stack and region without leaving the platform.

Pay by Zen Visa Mastercard Paysafecard PaysafeCash Skrill Trustly Bancontact UnionPay iDeal WebMoney