What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Set the keepInventory gamerule to true using an account with permission to run commands. The exact spelling differs between Minecraft editions—and, according to a September 2026 hosting guide, between Java versions—so use the command for your server below.
Use the command for your Minecraft edition
Enter the command in the server console without a leading slash, or in-game chat with a leading slash, if your account has permission to issue commands. Console and panel details can vary by host.
| # | Preview | Product | Price | |
|---|---|---|---|---|
| 1 |
|
Minecraft - Nintendo Switch | $29.83 | Buy on Amazon |
| 2 |
|
Minecraft: Switch Edition | $32.65 | Buy on Amazon |
| 3 |
|
Minecraft Legends Deluxe Edition | $49.00 | Buy on Amazon |
| 4 |
|
Minecraft | Standard Edition | XBOX Digital Code | $19.99 | Buy on Amazon |
| 5 |
|
Minecraft | Java & Bedrock Deluxe Collection | Windows Digital Code | $39.99 | Buy on Amazon |
| Server | Command | Where to enter it |
|---|---|---|
| Bedrock Dedicated Server | gamerule keepinventory true |
Server console; in-game, use /gamerule keepinventory true. |
| Java 1.21.11 and later | gamerule keep_inventory true |
Console; in-game, use /gamerule keep_inventory true. |
| Java 1.21.10 and older | gamerule keepInventory true |
Console; in-game, use /gamerule keepInventory true. |
The Java spelling split is reported in a server-hosting guide dated September 23, 2026, and is not corroborated here by a primary Mojang release note. If the command is rejected, check your server version and use command completion or version-specific official notes to confirm the accepted name. Shockbyte’s keepInventory guide.
Run it with sufficient permissions
Bedrock Dedicated Server
Microsoft documents keepinventory as the rule controlling whether players keep inventory when they die. Its command reference lists the Game Directors permission level for /gamerule and says the command does not require cheats. You can enter the command without a value to check the current rule, subject to the syntax accepted by your server build. Microsoft Learn: gamerule command.
Free tools Windows power users keep installed
One-click scans. No signup required.
#1 Best Overall
- Minecraft is a game about placing blocks and going on adventures
- Explore randomly generated worlds and build amazing things from the simplest of homes to the grandest of castles
- Play in creative mode with unlimited resources or mine deep into the world in survival mode, crafting weapons and armor to fend off the dangerous mobs
- Play on the go in handheld or tabletop modes
- Includes Super Mario Mash-Up, Natural Texture Pack, Biome Settlers Skin Pack, Battle & Beasts Skin Pack, Campfire Tales Skin Pack; Compatible with Nintendo Switch only
Bedrock Dedicated Server’s server.properties documents default-player-permission-level values of visitor, member, and operator. Use an account with appropriate command access. The same properties reference says allow-cheats controls whether cheat commands can be used; because Microsoft also says /gamerule does not require cheats, that setting alone does not explain every rejected command. Microsoft Learn: Bedrock Dedicated Server properties.
Java server
For in-game use, the account must be authorized to run commands; for a console, enter the command without the slash. Hosts may present console access differently. The version-specific spellings above follow the cited provider guide rather than a primary release note, so verify the name against your server build if needed.
Rank #2
- Explore randomly-generated worlds and build amazing things from the simplest of homes to the grandest of castles
- Play in Creative Mode with unlimited resources or mine deep into the world in survival mode, crafting weapons and armour to fend off the dangerous mobs
What changes when the rule is enabled
On Bedrock, Microsoft’s reference defines the rule as controlling whether players keep their inventory when they die. The cited hosting guide also says it preserves experience, but that secondary statement does not establish the behavior across every edition and version. Do not assume it guarantees that experience is retained on your server.
A Minecraft Feedback post describes a Bedrock Preview experiment involving inventory and enchantment retention on Easy or Peaceful while achievements remained active. That preview-specific report is not a promise about achievements in current Bedrock releases or every server configuration. Minecraft Feedback: Bedrock Preview experiment.
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Quick Recap
Best Value
- DELUXE COLLECTION — Includes Minecraft: Java & Bedrock Edition, three Bedrock add-ons, three exclusive Character Creator items, and 700 Minecoins.
- CREATE YOUR WORLD — Build whatever you imagine in an infinite world that’s unique in every playthrough.
- EXPLORE AND CRAFT — Discover biomes, resources, and mobs, then craft your way through a sandbox world filled with surprises.
- SURVIVE THE ADVENTURE — Face mysterious foes, travel across exciting landscapes, and venture into perilous dimensions.
- PLAY TOGETHER — Play cross-platform with friends in Bedrock Edition on console, mobile, and PC, or join community servers in Java Edition on PC, Mac, and Linux. Online console multiplayer requires a platform-specific subscription (sold separately).
Rank #4
- CREATE YOUR WORLD — Build whatever you imagine in an infinite world that is unique in every playthrough.
- EXPLORE AND CRAFT — Discover biomes, resources, and mobs, then craft your way through a sandbox world full of surprises.
- SURVIVAL ADVENTURES — Face mysterious foes, travel across varied landscapes, and venture into perilous dimensions.
- PLAY TOGETHER — Play solo or join friends in local split-screen and cross-platform play across console, mobile, and PC. Online multiplayer supports up to 8 players.
- COMMUNITY PLAY — Connect with players on community servers, or subscribe to Realms Plus (sold separately) to play with up to 10 friends on a private server.
Rank #3
Troubleshoot a rejected command
- Unknown or invalid gamerule: Confirm whether the server runs Java or Bedrock. For Java, check the exact server version and use the corresponding spelling in the table.
- Insufficient permission: Run the command from the server console or use an account authorized to issue administrative commands. On Bedrock Dedicated Server, review the player permission configuration and command access.
- Bedrock command blocked: Check permissions and server behavior. The
allow-cheatsproperty concerns cheat commands, but Microsoft says/gameruledoes not require cheats, so changing that property is not a definitive fix for every failure. - Rule seems unchanged elsewhere: Gamerules are world settings. The cited provider guide advises setting the rule in each separately managed world; plugin-based setups may handle worlds differently.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




