How to Enable or Disable Command Blocks on Your Minecraft Server

By VisPublished July 4, 2026Updated July 5, 20263 min read

Command blocks are special Minecraft blocks that can run server commands when activated. They are often used in adventure maps, minigames, custom worlds, and servers that want command-based features without using plugins or datapacks.

On a Minecraft server, command blocks are disabled by default on many hosts. Before you can use them, you need to enable command blocks in your server settings or by editing the server.properties file.

To place and edit a command block, you must be in Creative mode. On a server, you also need operator permissions.

You can give yourself a command block by running this command in the server console or in-game:

/give <username> minecraft:command_block

Replace <username> with your Minecraft username. If you're running it in console, then do not include the /.

Once you have the command block, place it down and right-click it to open the command block menu. If you cannot open or edit it, make sure you are opped, in Creative mode, and that command blocks are enabled on the server.

How to Enable Command Blocks on a Minecraft Server

Many Minecraft server hosts let you enable command blocks directly from the game panel.

  1. Open your server hosting panel.
  2. Find the server settings or configuration section.
  3. Look for a setting called Enable Command Blocks or Command Blocks.
  4. Set the option to Enabled.
  5. Save your changes.
  6. Restart the Minecraft server.

After the restart, command blocks should work on your server.

How to Disable Command Blocks on a Minecraft Server

You can also disable command blocks from your server panel.

  1. Open your server hosting panel.
  2. Go to the server settings or configuration section.
  3. Find the Enable Command Blocks or Command Blocks option.
  4. Set the option to Disabled.
  5. Save your changes.
  6. Restart the server.

Once disabled, command blocks will no longer run commands on the server.

How to Enable or Disable Command Blocks Using server.properties

If your host does not have a game panel, or if you are self-hosting your Minecraft server, you can enable or disable command blocks by editing the server.properties file.

  1. Stop your Minecraft server.
  2. Open your server folder.
  3. Find the server.properties file.
  4. Open the file in a text editor.
  5. Find this line:

enable-command-block=false

To enable command blocks, change it to:

enable-command-block=true

To disable command blocks, change it back to:

enable-command-block=false

  1. Save the file.
  2. Start the server again.

The change will only apply after the server has been restarted.

Why Are Command Blocks Disabled by Default?

Command blocks can run powerful commands, so they should only be used by trusted players and server owners. If someone has access to command blocks, they may be able to change the world, give items, teleport players, or run other server commands.

For public Minecraft servers, it is usually best to keep command blocks disabled unless you specifically need them for maps, minigames, or custom server features.

Command Blocks Still Not Working?

If command blocks are not working after you enabled them, check the following:

Once these settings are correct, command blocks should be enabled and ready to use on your Minecraft server.

Find Minecraft Servers

Ready to compare active communities? Browse ranked Minecraft servers by votes, tags, and supported versions.

More Minecraft Guides