Command Block in Minecraft

Minecraft 26.3

How to obtain, what distinguishes the three types, how to configure, and why the block is silent — by game signatures and rules.

  • 3 view
  • a level is needed 2
  • Minecraft 26.3
My Game select version

Save your preferences in this browser and apply them to supported tools. Settings in a shared link take priority. Wiki version labels are not affected.

On this page 8 sections

At a glance

Get — /give, place — in creative and survival mode

  • Get a command block
    /give @s minecraft:command_block
  • Enable command blocks
    /gamerule command_blocks_work true
  • Remove their chat messages
    /gamerule command_block_output false

Command blocks cannot be obtained in survival mode—only by command /give @s minecraft:command_block. It can be placed and configured in creative mode or with operator level 2 permissions. Blocks function as long as the game rule is enabled command_blocks_work.

How to get a command block?

  1. Enable cheats (in single-player) or gain operator permissions (on a server).
  2. Write in chat /give @s minecraft:command_block — the block will appear in the inventory.
  3. Or enable the tab: 'Settings...' → 'Management...' → 'Operator Tab'. Then, in the creative inventory, the 'Operator Tools' tab with command blocks will appear.

Without creative mode or operator permissions, the game does not allow opening a block: 'The player must have operator status and be in creative mode.' In survival mode, a command block does not spawn from nowhere — it appears in the list. unobtainable blocks.

Three types of command blocks

BlockModeHow does it trigger?The command
Command BlockImpulsiveTriggers once per redstone signal./give @s minecraft:command_block
Repeating Command BlockCyclicTriggers every tick (20 times per second) while enabled./give @s minecraft:repeating_command_block
Chain Command BlockChainTriggers after the block it points to: this is how command chains are built./give @s minecraft:chain_command_block

Mode changes directly in the block window — one block can be switched to any of the three. There's also a 'Minecart with Command Block': activates when it passes over activated rails.

How to set up

Right-click on a block — a window will open. Enter a command in the "Console Command" field, either with or without a slash. Then, three toggles follow:

  • Impulse, Cyclic, Chain — block types
  • "Unconditional" or "Conditional" — a conditional block executes only if the previous block in the chain successfully executed the command;
  • 'Need signal' or 'Always active' — wait for redstone signal or work independently.

Previous output shows what the command responded with last time — the first place to check if a block is behaving incorrectly.

Why isn't the Command Block working?

  • Disabled game rule command_blocks_work — blocks stand silently and the game displays "Command blocks are disabled" when configuring. Enable by — /gamerule command_blocks_work true.
  • On servers older than 1.21.9, this was handled by the key enable-command-block in server.properties — disabled by default. Starting from 1.21.9, it's gone; only the game rules remain
  • A redstone signal is required for a pulse block, while a repeater and a sequence block require 'Signal needed' without a signal.
  • Error in the command — see 'Previous output' in the block window.

How to remove command block messages from chat

Command blocks' responses are seen by operators in chat, and a repeating block floods it with messages. This rule is disabled in the game. command_block_output: /gamerule command_block_output false. Who can run which commands — on the page operator levels.

Frequently asked questions

How to get a command block in Minecraft?

The command /give @s minecraft:command_block cannot be obtained in survival mode. In creative mode, it is available in the Operator Tools tab if enabled: Settings... → Management → Operator Tab.

Why isn't the Command Block working?

If the command_blocks_work game rule is disabled, command blocks stand idle and do nothing. A redstone pulse-powered block requires a repeating or square pulse signal, or the 'Always Active' mode.

How to remove command block messages from chat?

Disable the command_block_output rule: /gamerule command_block_output false.

More in the wiki

Minecraft 26.3 data: menu and text captions — from game localization, rules — from client code and game report.