How to Use Fill Command in Minecraft

In Short
  • Fill command lets you create cubes or cuboids by inserting two of its diagonal points.
  • Thanks to various command keywords like replace, destroy, hollow, outline and keep, you have more freedom when creating cuboids.
  • In order to use the fill command in Minecraft you have to enable cheats and by viewing your coordinates, you can make more precise placements.

Building structures is one of the most exciting parts of playing Minecraft. The possibilities are endless. But if you are anything like me, the task of placing around thousands of blocks to create a structure feels overwhelming. Luckily for both of us, the game has a special feature that can help you make the building process so much easier and faster. With that said, let’s learn how to use the fill command in Minecraft and change building forever!

Last updated on February 19, 2024 to better explain fill command modifiers and add new images

How to Use Fill Command in Minecraft

In order to use the fill command, you’ll need to have cheats enabled. Also, knowing your current coordinates is fairly useful. So, feel free to use the table above to skip to the sections in this guide explaining how to enable cheats and view coordinates. If you’re ready though, let’s start learning how to use the fill command in-game right away.

1. Use the Fill Command with Coordinates

  • First, look for an open area where you want to build a structure. If you are in creative mode, you can even fly and choose to build in the air. As you will later see, we can also use the “/fill” command to clear an area by removing its blocks.
  • Go to a specific corner of the area you want to fill and record its coordinates. Then go to the opposite corner of that area and record its coordinates. It has to be diagonally opposite to the first corner you selected. You need to note down the X, Y, and Z coordinates of both spots separately.
Two blocks placed diagonally from each other
  • Then, open up the chat menu and type the following command:
/fill x1 y1 z1 x2 y2 z2 <name of the block>

Here x1, y1, and z1 are the coordinates of the first corner, and similarly, x2, y2, and z2 are the coordinates of the second corner. Meanwhile, the <name of the block> has to be replaced with the name of the in-game block you want to use to fill that given area. For example: “/fill 1380 65 -5193 1389 74 -5202 minecraft:diamond_block” will spawn a huge cuboid made of diamond blocks.

2. Use the Fill Command Without Coordinates

Now that you know how to use the fill command, it’s time to make it a bit easier. Instead of going from corner to corner, you can also make a structure next to yourself if you know its size. Let’s assume you want to make a cuboid, which is twenty blocks in height, ten in width, and five in breadth. So, the command you need to use will look like this:

/fill ~ ~ ~ ~10 ~20 ~5 <name of the block>

Here the “~” symbol denotes your current coordinates. Then the integer next (~10) to it is perceived as a number of blocks before or after that position. So, ~ ~ ~ is your current position. Meanwhile, ~ ~-10 ~ is ten blocks below you, and ~ ~20 ~ is twenty blocks above you.

3. Which Blocks Can You Use in Fill Command

Usually, Minecraft structures can be built using only common building blocks – planks, stones, and others. They are completely square blocks with no additional features. But that’s not the case with the “/fill” command. This command allows you to use every placeable block in the game to make a structure. The game even suggests the name of such blocks while you are typing the command. Also, you can even use some unplaceable entities like light and air with this command.

Note: Do keep in mind that blocks such as veins and buttons might break when placed mid-air. Similarly, using liquids like lava or water to make structures won’t stop their flow after being spawned.

Minecraft Fill Command Modifiers

Once you get the hang of the basic “/fill” command, you can take it a step further by changing how the game handles each structure. There are some keywords or subcommands that you can use after the fill command to customize it. Let’s now go over each of them.

1. Replace

The most common way to use the fill command is with the “replace” keyword. By default, the structures you place using the fill command replace every single existing block in that area. But with the “replace” keyword, only the targeted blocks are removed. Its syntax is:

/fill x1 y1 z1 x2 y2 z2 <name of the block A> replace <name of the block B>

Here, X, Y, and Z are coordinates of the target area, as we’ve covered earlier. Meanwhile, “name of the block A” is the block you want to place in your structure. And “name of the block B” is the existing block you want to replace with “block A”. If you use air to replace a certain area, you can basically clear chunks of your structure in Minecraft.

2. Destroy

You can use the “destroy” keyword to fill the targeted area with the chosen block, but it also drops all removed blocks as items, as if the player mined them manually. When used underground, the result looks similar to the pattern of stripped mined areas. Its syntax is:

/fill x1 y1 z1 x2 y2 z2 <name of the block> destroy

3. Hollow

Next up, “hollow” is an interesting keyword to use with the fill command. With it, only the external layer of the structure is spawned. So, instead of a fully filled one, you get a hollow cuboid. Its syntax is:

/fill x1 y1 z1 x2 y2 z2 <name of the block> hollow

If you are wondering about the existing blocks within the structure, they get instantly replaced with air. So, the resulting structure is hollow even if it had existing blocks in its empty area.

4. Outline

The “outline” keyword is quite similar to “hollow”. It also only spawns the external structure of your command. But if you use “outline”, the existing blocks on the inside of the structure remain intact. This is a useful option to trap existing Minecraft mobs and structures in hollow cuboids. The syntax goes as follows:

/fill x1 y1 z1 x2 y2 z2 <name of the block> outline

5. Keep

Finally, the last modifier keyword of the fill command is “keep”. It ensures that none of the existing blocks in the area are affected by the spawned structure. Its syntax is

/fill x1 y1 z1 x2 y2 z2 block keep

Another way to understand “keep” is that if you don’t have empty or air blocks in the target area, then parts of your structure won’t spawn. The existing blocks of the area won’t be destroyed or replaced.

Note:

On the Bedrock Edition, you have to type “1” before every keyword for it to be activated. Example: /fill x1 y1 z1 x2 y2 z2 block 1 outline. This number gives you additional information on the block’s behavior in a binary format.

How Does the Fill Command Work

The fill command, as the name reveals, is used to fill areas with a set of blocks. But that’s not all. You can use this command to destroy and replace existing blocks as well. With that ability, you can create a variety of basic structures without manually placing a single block by hand. Here are a few basics of the fill command that you should know:

  • You can only target a specific block within a single command line.
  • Fill command can’t place blocks in the void or beyond the world limit.
  • It can place up to 32,768 blocks at once.
  • You have to enter specific coordinates to start and stop placing blocks.
  • Spawning blocks is generally a heavy task. So, using the fill command can easily crash your game if you push it over the edge.
  • All fill command structures are some forms of cuboids or lines.

How to Enable Commands or Cheats in Minecraft

Commands in Minecraft work basically the same way as cheats function in other video games. So, you must enable cheats in your world to use any command. Without doing so, you can’t use the fill command. So, let’s see how to enable cheats in Java and Bedrock editions.

Enable Cheats in Minecraft Bedrock

Follow these steps to enable cheats in Minecraft Bedrock. The steps are the same for all Bedrock platforms, including consoles, PCs, and MCPE.

  • To begin, press the “ESC” key or your platform’s pause key. Then, click on the “Settings” option in the pause menu.
  • Next, within the “Game” section of the settings, look for the “Cheats” section by scrolling down. Under this section, toggle the “Activate Cheats” option.

Enable Cheats in Minecraft Java

Follow these steps to enable cheats in an existing Minecraft Java world:

  • First, press the “Esc” key to open the pause menu. Here, click on the “Open to LAN” button. You don’t need to play multiplayer or have an internet connection to use it.
  • Then turn on the “Allow Cheats” option by clicking on it. Once done, click on the “Start LAN World” button.

Use Cheats in Minecraft

After you have enabled cheats in your Minecraft world, it’s simple to use them. You just need to open the chatbox on both Minecraft Java and Bedrock edition. If you are on a PC, you can do so using the “T” key. Meanwhile, the console users have to press their dedicated chat key to open it. As for the MCPE users, Minecraft has a dedicated chat button at the top.

Within the chat, you just have to type “/” (slash but without quotation marks) followed by your command and its attributes. For example, sending a text that reads “/summon sheep” in your chat spawns a sheep right in front of you. We can also add a variety of attributes to make such simple commands way more useful.

How to View Coordinates in Minecraft

Now that we know how to enable cheats, let’s see how you can find coordinates in your Minecraft version, as it’ll be very helpful while using this command.

See Coordinates in Java Edition

Things are much simpler for players on the Java edition. Press the “F3” key to open the debug screen within your world and the current coordinates will be visible in the informational overlay. The coordinates are displayed in the dimensional format, denoting X, Y, and Z values clearly (see screenshot below).

See Coordinates in Bedrock Edition

Bedrock users don’t have a dedicated key to make their coordinates visible. Instead, they have to turn on the “Show Coordinates” option within the game or world settings. Once done, their current coordinates will be visible at the top left corner of the screen.

Whether you want to surround your village with blocks or create empty spaces, the fill command is there to help. It can be a bit overwhelming to begin using the fill command in Minecraft. But with practice and experimentation, you will be natural at it in no time. With that said, the fill command has a diversity of uses, and we are just scratching the surface of its creativity. But what are you planning to do with it? Tell us in the comments!

Can you undo a Fill command?

You can’t undo the fill command once executed. That’s why you should use the “keep” keyword to avoid accidentally destroying your structures.

What is the command to clear a large area in Minecraft?

To clear a large area in Minecraft, you can replace that area’s blocks with air. To do so, use the following syntax of the fill command:
/fill x1 y1 z1 x2 y2 z3 air

Are the commands the same in all versions of Minecraft?

After almost every other update, Minecraft receives new commands as well as changes to the existing commands. If you want to use this command on versions older than 1.12, you should refer to Minecraft Wiki to avoid errors.

#Tags
Comments 5
Leave a Reply

Loading comments...