OGTOOLS

Minecraft /fill command

Fills, clears or hollows out the box between two corners with the block you choose.

🧱 Blocks and structures Operator (level 2) Needs cheats enabled Java Edition 26.3

Syntax

/fill <from> <to> <block> [replace [<filter>]|destroy|hollow|outline|keep]

Parts in square brackets are optional, parts in angle brackets are required. You do not type the brackets: Put your own value in their place.

Arguments

ArgumentWhat it does
hollow Fills only the outer shell and makes the inside air.
outline Fills the outer shell and leaves the inside untouched.
replace <filter> Replaces only the old block you specify.

Examples

/fill ~-5 ~ ~-5 ~5 ~ ~5 stone

Lays an 11 x 11 stone floor around you.

/fill ~-10 ~-1 ~-10 ~10 ~5 ~10 air

Deletes everything around you and clears the area.

/fill ~-8 ~ ~-8 ~8 ~6 ~8 glass hollow

Builds a hollow glass box.

/fill ~-20 ~ ~-20 ~20 ~ ~20 grass_block replace dirt

Turns only the dirt into grass blocks.

Good to know

  • A single command handles at most 32768 blocks; split larger areas into parts.
  • The destroy option drops items and strains the server over large areas.

How do I run this command?

Press T in game to open chat (or press / directly), type the command and press Enter. While typing, Tab completes the options. This command counts as a cheat: It needs cheats enabled in a singleplayer world, and operator permission on a server (operator (level 2)).

Related commands

🧱 More Blocks and structures

Another tool Minecraft crafting recipes Would rather make the item than give it with a command? See the recipe on the 3x3 grid.

Minecraft is a product of Mojang Studios. This tool is an independent helper made for players and is not affiliated with Mojang or Microsoft.