I am running a 1.12 Minecraft Realms server, playing Survival Multiplayer, and there are quite a few players playing on it. The problem is that I sometimes encounter a player stealing other player's items from chests.

My goal is to prevent this form happening by somehow blocking the chest inventory from some players.

The problem is: How can I do this? Is there even a way to protect a player's chest from other players?

  • Just saying testfor doesn't replace research. What have you tried? Have you looked into the Lock tag? When do you actually want to do something? What is your plan? Jan 28, 2018 at 15:10
  • A good way is to hide the chest in a room with no door. Then you can use /testfor or whatever to open a doorway. And try some research. Questions like that have been asked multiple times.
    – dly
    Jan 28, 2018 at 17:01
  • This is a challenge. If you don't want people stealing, kicking players who do is probably the easiest solution if you can prove who it was. You can also instruct players to hide their valuable items. Hacked clients can make this difficult to do as they can help locate blocks with inventories. They can travel a distance from spawn to help hide items but this can make it difficult to build with others. Players can craft ender chests to keep items safe but they only get one inventory, they need to obtain items to craft them, and need silk touch to move them once placed.
    – IronAnvil
    Jan 28, 2018 at 17:39

2 Answers 2


I too have a realm and what you could possibly do is turn keepinventory on if It isn’t already and just give players loads of skulker boxes which they can use to store items instead of placed chests. Sadly, i can’t find a way to make chests invincible and locked without plugins or mods so this might be the way to go. Sorry if this wasn’t the answer you were looking for.

  • I had mentioned ender chests in the comments above. It is meant to be a chest that can be accessed anywhere in the world. Since it's inventory is stored in player data, it forms a sort of safe deposit box. With the addition of shulker boxes, you can store a lot of items in the single inventory of the ender chest (729 slots max). This could be used to avoid requiring players carry everything and/or eliminate the need to toggle keepInventory.
    – IronAnvil
    Jan 31, 2018 at 1:51

You can lock chests with {Lock:"Key Name"} and if you have a item with that name, you can open the chest when right clicking it with the named item.

/blockdata ~ ~-1 ~ {Lock:"Key Name"}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .