All Minecraft commands
114 Java and Bedrock commands with their syntax. Pick one to open its generator, written for your exact version.
114 of 114 commands
/ability
bedrockGrants or revokes a player ability (Education Edition worlds: mayfly, mute, worldbuilder).
ability <player> <ability> [true|false]No generator yet: ask the AI/advancement
javaGrants or revokes advancements and their criteria.
advancement grant|revoke <targets> only|from|until|through|everything …Related: Advancement generator/aimassist
bedrockTurns aim assist on or off for players, with a preset and target distance.
aimassist <players> set|clear [x_angle] [y_angle] [max_distance] [target_mode] [preset_id]No generator yet: ask the AI/allowlist
also /whitelistbedrockManages the server allowlist (Bedrock Dedicated Server).
allowlist add|remove|list|on|off|reload <player>No generator yet: ask the AI/alwaysday
also /daylockbedrockLocks the time of day (stops the day-night cycle).
alwaysday [true|false]Related: /time generator/attribute
javaReads or changes an entity's attributes and attribute modifiers.
attribute <target> <attribute> get|base|modifier …Open the /attribute generator/ban
javaBans a player from the server.
ban <targets> [reason]No generator yet: ask the AI/ban-ip
javaBans an IP address from the server.
ban-ip <target> [reason]No generator yet: ask the AI/banlist
javaLists banned players or IPs.
banlist [ips|players]No generator yet: ask the AI/bossbar
javaCreates and changes boss bars: name, color, style, value and who sees them.
bossbar add|set|remove|get|list …Open the /bossbar generator/camera
bedrockMoves the player's camera: presets, easing, fades and cutscenes.
camera <players> set <preset> [ease …] [pos …] [rot …] | fade | clearOpen the /camera generator/camerashake
bedrockShakes the camera of players for a while.
camerashake add <player> [intensity] [seconds] [positional|rotational] | stopNo generator yet: ask the AI/changesetting
bedrockChanges a server setting while the server runs (Bedrock Dedicated Server).
changesetting allow-cheats|difficulty <value>No generator yet: ask the AI/clear
javabedrockRemoves items from players' inventories, or counts them.
clear [targets] [item] [maxCount]Open the /clear generator/clearspawnpoint
bedrockRemoves players' spawn point so they respawn at world spawn.
clearspawnpoint [player]No generator yet: ask the AI/clone
javabedrockCopies a box of blocks to another place.
clone <begin> <end> <destination> [replace|masked|filtered] [force|move|normal]Open the /clone generator/connect
also /wsserverbedrockConnects the game to a WebSocket server.
connect <serverUri>No generator yet: ask the AI/damage
javabedrockDeals damage of a given type to entities.
damage <target> <amount> [damageType] [at <location> | by <entity> [from <cause>]]Open the /damage generator/data
javaReads and edits the NBT of blocks, entities and command storage.
data get|merge|modify|remove block|entity|storage …Open the /data generator/datapack
javaEnables, disables, lists or creates data packs.
datapack enable|disable|list|create …No generator yet: ask the AI/debug
javaStarts or stops a debug profiling session.
debug start|stop|function <name>No generator yet: ask the AI/defaultgamemode
javabedrockSets the game mode new players get.
defaultgamemode <mode>Open the /defaultgamemode generator/deop
javabedrockTakes operator status from a player.
deop <targets>No generator yet: ask the AI/dialog
javaShows or clears a dialog screen (Java 1.21.6+).
dialog show <targets> <dialog> | clear <targets>No generator yet: ask the AI/dialogue
bedrockOpens or changes an NPC dialogue for players.
dialogue open <npc> <player> [scene] | change <npc> <scene> [players]No generator yet: ask the AI/difficulty
javabedrockSets the difficulty: peaceful, easy, normal or hard.
difficulty [peaceful|easy|normal|hard]No generator yet: ask the AI/effect
javabedrockGives or clears status effects.
effect give <targets> <effect> [seconds] [amplifier] [hideParticles] | clearOpen the /effect generator/enchant
javabedrockEnchants the item a player holds.
enchant <targets> <enchantment> [level]Open the /enchant generator/event
bedrockTriggers an entity event defined in a behaviour pack.
event entity <target> <eventName>No generator yet: ask the AI/execute
javabedrockRuns a command as, at or under conditions; stores results.
execute as|at|positioned|if|unless|store … run <command>Open the /execute generator/experience
also /xpjavabedrockAdds, sets or reads experience points and levels.
experience add|set|query <targets> <amount> [levels|points] · Bedrock: xp <amount>[L] [player]Open the /xp (experience) generator/fill
javabedrockFills a box with blocks: hollow, outline, replace or destroy.
fill <from> <to> <block> [destroy|hollow|keep|outline|replace [filter]]Open the /fill generator/fillbiome
javaChanges the biome of a box of blocks.
fillbiome <from> <to> <biome> [replace <filter>]Open the /fillbiome generator/fog
bedrockPushes or removes fog settings for players.
fog <victim> push|pop|remove <fogId> <userProvidedId>No generator yet: ask the AI/forceload
javaKeeps chunks loaded even with no player nearby.
forceload add|remove <from> [to] | remove all | query [pos]Open the /forceload generator/function
javabedrockRuns a function from a data pack or behaviour pack.
function <name> [arguments | with <source>]Open the /function generator/gamemode
javabedrockChanges players' game mode.
gamemode <mode> [targets]Open the /gamemode generator/gamerule
javabedrockReads or changes a game rule.
gamerule <rule> [value]Open the /gamerule generator/gametest
bedrockRuns GameTest Framework tests (needs the beta APIs experiment).
gametest run|runset|clearall|pos|create …No generator yet: ask the AI/give
javabedrockGives items, with enchantments, names and components.
give <targets> <item>[components] [count]Open the /give generator/help
also /?javabedrockLists commands or shows one command's usage.
help [command]No generator yet: ask the AI/hud
bedrockHides or shows parts of the HUD.
hud <target> hide|reset [element]Open the /hud generator/immutableworld
bedrockMakes the world read-only (Education Edition).
immutableworld [true|false]No generator yet: ask the AI/inputpermission
bedrockTurns player input on or off: camera, movement, jump, sneak and more.
inputpermission set <targets> <permission> enabled|disabled | queryNo generator yet: ask the AI/item
javaReplaces or modifies items in inventory and container slots.
item replace|modify block|entity <target> <slot> …Open the /item generator/jfr
javaStarts or stops Java Flight Recorder profiling.
jfr start|stopNo generator yet: ask the AI/kick
javabedrockDisconnects a player from the server.
kick <targets> [reason]No generator yet: ask the AI/kill
javabedrockKills entities, or yourself with no target.
kill [targets]Open the /kill generator/list
javabedrockLists the players online.
list [uuids]No generator yet: ask the AI/locate
javabedrockFinds the nearest structure or biome.
locate structure|biome|poi <id>Open the /locate generator/loot
javabedrockDrops or gives the items of a loot table, a mob's drops or a mined block.
loot give|insert|spawn|replace … loot|kill|mine|fish …Related: Loot table generator/me
javabedrockShows an action message in chat (* Steve waves).
me <action>No generator yet: ask the AI/mobevent
bedrockTurns mob events such as pillager patrols or wandering traders on or off.
mobevent <event> [true|false]No generator yet: ask the AI/msg
also /tell, /wjavabedrockSends a private message.
msg <targets> <message>Related: /tellraw generator/music
bedrockPlays, queues or stops music tracks.
music play|queue|stop|volume <track> [volume] [fade] [loop|play_once]Related: /playsound generator/op
javabedrockMakes a player an operator.
op <targets>No generator yet: ask the AI/pardon
javaRemoves a player from the ban list.
pardon <targets>No generator yet: ask the AI/pardon-ip
javaRemoves an IP from the ban list.
pardon-ip <target>No generator yet: ask the AI/particle
javabedrockShows particles at a place.
particle <name> [pos] [delta] [speed] [count] [force|normal] [viewers]Open the /particle generator/perf
javaCaptures 10 seconds of performance data.
perf start|stopNo generator yet: ask the AI/permission
also /opsbedrockReloads or lists permissions (Bedrock Dedicated Server).
permission list|reloadNo generator yet: ask the AI/place
javaPlaces a feature, structure, template or jigsaw.
place feature|structure|template|jigsaw <id> [pos] …Open the /place generator/playanimation
bedrockPlays an animation on entities.
playanimation <entity> <animation> [next_state] [blend_out_time] [stop_expression] [controller]No generator yet: ask the AI/playsound
javabedrockPlays a sound to players.
playsound <sound> [source] [targets] [pos] [volume] [pitch] [minVolume]Open the /playsound generator/publish
javaOpens a single-player world to LAN.
publish [allowCommands] [gamemode] [port]No generator yet: ask the AI/random
javaRolls a random number, privately or for everyone.
random value|roll <range> [sequence] | reset <sequence>Open the /random generator/recipe
javabedrockUnlocks or locks recipes in players' recipe books.
recipe give|take <targets> <recipe|*>Related: Recipe generator/reload
javabedrockReloads data packs (Java) or functions and scripts (Bedrock).
reload [all]No generator yet: ask the AI/replaceitem
bedrockPuts an item into an inventory or container slot.
replaceitem entity|block <target> <slot> <slotId> [destroy|keep] <item> [amount] [data] [components]Related: /item generator/return
javaEnds a function and returns a value (Java 1.20.3+).
return <value> | fail | run <command>No generator yet: ask the AI/ride
javabedrockMakes entities mount or dismount others.
ride <target> mount <vehicle> | dismount · Bedrock: ride <riders> start_riding|stop_riding|evict_riders|summon_rider|summon_ride …Open the /ride generator/rotate
javaTurns an entity to an angle or to face something (Java 1.21.2+).
rotate <target> <rotation> | facing <pos> | facing entity <entity>Related: /tp generator/save
bedrockHolds, queries or resumes world saving for backups.
save hold|query|resumeNo generator yet: ask the AI/save-all
javaSaves the world to disk.
save-all [flush]No generator yet: ask the AI/save-off
javaTurns automatic saving off.
save-offNo generator yet: ask the AI/save-on
javaTurns automatic saving back on.
save-onNo generator yet: ask the AI/say
javabedrockSends a message to every player.
say <message>Related: /tellraw generator/schedule
javabedrockRuns a function later (Java) or when an area loads (Bedrock).
schedule function <function> <time> [append|replace] | clear <function> · Bedrock: schedule on_area_loaded add …Open the /schedule generator/scoreboard
javabedrockCreates objectives and changes players' scores.
scoreboard objectives|players …Open the /scoreboard generator/scriptevent
bedrockSends an event to behaviour-pack scripts.
scriptevent <messageId> <message>No generator yet: ask the AI/seed
javaShows the world seed.
seedNo generator yet: ask the AI/setblock
javabedrockPlaces one block, with block states and NBT.
setblock <pos> <block> [destroy|keep|replace]Open the /setblock generator/setidletimeout
javaKicks players idle for this many minutes.
setidletimeout <minutes>No generator yet: ask the AI/setmaxplayers
bedrockSets the most players the world allows.
setmaxplayers <maxPlayers>No generator yet: ask the AI/setworldspawn
javabedrockSets the world spawn point.
setworldspawn [pos] [angle]No generator yet: ask the AI/spawnpoint
javabedrockSets players' spawn point.
spawnpoint [targets] [pos] [angle]No generator yet: ask the AI/spectate
javaMakes a spectator watch through an entity's eyes.
spectate [target] [player]Open the /spectate generator/spreadplayers
javabedrockTeleports entities to random spots in an area.
spreadplayers <center> <spreadDistance> <maxRange> [under <maxHeight>] <respectTeams> <targets>Open the /spreadplayers generator/stop
javabedrockStops the server.
stopNo generator yet: ask the AI/stopsound
javabedrockStops sounds playing for players.
stopsound <targets> [source] [sound]Related: /playsound generator/structure
bedrockSaves, loads or deletes structures.
structure save|load|delete <name> …Related: /clone generator/summon
javabedrockSpawns a mob or entity with NBT, riders and equipment.
summon <entity> [pos] [nbt]Open the /summon generator/tag
javabedrockAdds, removes or lists entity tags (for selectors).
tag <targets> add|remove <name> | listRelated: Target selector generator/team
javaCreates teams and sets colors, prefixes, friendly fire and more.
team add|remove|join|leave|modify|empty|list …Open the /team generator/teammsg
also /tmjavaSends a message to your team.
teammsg <message>No generator yet: ask the AI/teleport
also /tpjavabedrockTeleports entities to a place or another entity, with rotation.
teleport <targets> <location> [rotation | facing …]Open the /tp generator/tellraw
javabedrockSends a rich text message: colors, click and hover events.
tellraw <targets> <message>Open the /tellraw generator/test
javaRuns and manages GameTests (Java 1.21.5+).
test run|runall|create|locate|… <tests>No generator yet: ask the AI/testfor
bedrockCounts entities matching a selector.
testfor <victim>Related: Target selector generator/testforblock
bedrockTests whether a block is at a position.
testforblock <pos> <block> [states]Related: /execute generator/testforblocks
bedrockTests whether two areas have the same blocks.
testforblocks <begin> <end> <destination> [masked|all]Related: /execute generator/tick
javaFreezes, steps or speeds up the game tick (Java 1.20.3+).
tick query|rate <rate>|freeze|unfreeze|step [time]|sprint <time>No generator yet: ask the AI/tickingarea
bedrockKeeps areas loaded (Bedrock's /forceload).
tickingarea add <from> <to> [name] | add circle … | remove … | remove_all | listRelated: /forceload generator/time
javabedrockSets, adds or reads the time of day.
time set|add|query …Open the /time generator/title
javabedrockShows titles, subtitles and action-bar text.
title <targets> title|subtitle|actionbar|times|clear|reset …Open the /title generator/titleraw
bedrockShows titles with JSON raw text.
titleraw <player> title|subtitle|actionbar <rawtext>Open the /title generator/toggledownfall
bedrockToggles rain on or off.
toggledownfallRelated: /weather generator/transfer
javaSends players to another server (Java 1.20.5+).
transfer <hostname> [port] [players]No generator yet: ask the AI/trigger
javaLets non-op players change a trigger objective.
trigger <objective> [add|set <value>]Related: /scoreboard generator/version
javaShows the server's game version (Java 1.21.6+).
versionNo generator yet: ask the AI/waypoint
javaLists and styles locator-bar waypoints (Java 1.21.6+).
waypoint list | modify <waypoint> color|style …No generator yet: ask the AI/weather
javabedrockSets clear weather, rain or thunder.
weather clear|rain|thunder [duration]Open the /weather generator/whitelist
javaManages the server whitelist.
whitelist add|remove|list|on|off|reload <player>No generator yet: ask the AI/worldborder
javaMoves, grows or shrinks the world border.
worldborder set|add|center|damage|warning|get …Open the /worldborder generator
Item, mob and data pack builders
These generators write a /give, /summon or /setblock with deep NBT, or the JSON files of a data pack.
Not here? Describe it
Write what the command should do. The AI fills the matching generator, or writes the command when there is none yet.
Describe it — AI writes the command
Type what you want in plain words. The AI picks the generator and opens it with the form filled in, so you can check and change anything.
Checking the AI…