World
/setblock
Place a single block.
Syntax
Parameters
- pos
- block coords
- Where to place the block.
- block
- block ID
- What to place.
- modeoptional
- literal
- destroy / keep / replace (default replace).
Command builder
Configure the options below to generate a ready-to-paste /setblock command.
Blank = ~ (your position).
/setblock ~ ~ ~ minecraft:stoneExamples
Place a diamond block at your feet.
Place a command block at world spawn level.
Permission level
/setblock requires Cheats (op level 2). In single-player you need the world's "Allow Cheats" toggle on. On a multiplayer server you need to be opped — see /op.