Forgot password
Enter the email address you used when you joined and we'll send you instructions to reset your password.
If you used Apple or Google to create your account, this process will create a password for your existing account.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.
Reset password instructions sent. If you have an account with us, you will receive an email within a few minutes.
Something went wrong. Try again or contact support if the problem persists.
Minecraft Setblock Command being used.

How to Use the Setblock Command in Minecraft

Need your block to have more advanced features? Use /setblock!

The /setblock command in Minecraft allows the user to change a block at a specific coordinates in their current Minecraft world to the block specified. The usage and syntax of this command depends on which platform (Java or Bedrock) you are using it. You can see both versions of the syntax below and what to use for each argument (the conditions after the command itself).

Recommended Videos

Java

Using the command in Java is fairly straightforward and just as customizable as using the command in Bedrock. The syntax is as follows:

/setblock <pos> <block> [destroy|keep|replace]

Example: /setblock 45 70 200 minecraft:furnace[facing=north]{BurnTime:200} replace

Result: Sets a north-facing furnace at position 45 70 200 that burns for 200 ticks. Replaced block does not make a sound or drop contents.

Arguments

  • <pos>: The position of the block to change. Must comprise x y z coordinates including floating-point numbers, tildes, or caret notations.
  • <block>: The block and arguments to use to set specifics about the block, such as direction and other customization options. Unlike Bedrock, the additional conditions must be added as a part of this argument.
  • [destroy | keep | replace]: Additional option for how to handle placing the new block. Must use only one.
    • destroy: Destroys the block as if a player in Survival destroyed it. Plays the block breaking sound and drops its contents.
    • keep: Only replaces air blocks.
    • replace: Sets the position to the new block, does not play a block breaking sound, and does not drop contents.

Related: Best Minecraft Challenge Maps

Bedrock

In Bedrock, the command tends to be more complicated and requires additional input for specific arguments. The syntax is as follows:

/setblock <position: x y z> <tileName: Block> [blockStates: block states] [destroy | keep | replace]

Example 1: /setblock 45 70 200 stone_slab ["stone_slab_type": "Quartz", "facing direction":3] destroy

Result: Places an east-facing Quartz Stone Slab at 45 70 200 that destroys the replaced block and drops its contents.

  • <pos>: The position of the block to change. Must comprise x y z coordinates including floating point numbers, tilde, or caret notations.
  • <tileName: Block>: The block to place. Must use block_id.
  • [blockStates]: Addition arguments to use after the tileName argument that specify features about the block being placed.
  • [destroy | keep | replace]: Additional option for how to handle placing the new block. Must use only one.
    • destroy: Destroys the block as if a player in Survival destroyed it. Plays the block breaking sound and drops its contents.
    • keep: Only replaces air blocks.
    • replace: Sets the position to the new block, does not play a block breaking sound, and does not drop contents.

Those are the basics for using the /setblock command! For additional Minecraft guides and content, be sure to visit our Minecraft homepage!

Using the setblock command is a necessary tool in making Adventure Maps in Minecraft! Check out our full list of the Best Adventure Maps to get some ideas for creating your own!


Pro Game Guides is supported by our audience. When you purchase through links on our site, we may earn a small affiliate commission. Learn more about our Affiliate Policy
We have upgraded our commenting platform! Existing comments will be imported over the next few weeks.
Author
Image of Nicholas Fries
Nicholas Fries
Freelance writer and jack-of-all-hobbyist-tech-development-trades (website, game, and program). My passion is to create content that entertains and makes people think critically.