Minecraft (Java and Bedrock) Cheats
Minecraft has no old-style cheat codes; instead it uses native slash commands typed into the chat box (or run from command blocks). Commands only work when "Allow Cheats" (Java) / "Activate/Allow Cheats" (Bedrock) is enabled for the world, or when you are a server operator. Once cheats are on, the command syntax is essentially identical across every platform, so most codes are listed as platform "All"; the few differences are between the Java and Bedrock editions rather than between hardware platforms.
38 cheats // pick your platform below

Heads up // Achievements/Trophies: In BEDROCK Edition, enabling cheats PERMANENTLY disables achievements for that world on every platform (Windows, mobile, PlayStation, Xbox, Switch). A common workaround is to leave cheats off at world creation and instead enable them temporarily for a single session via 'Open to LAN' > Allow Cheats: ON (achievements stay enabled until you reload). In JAVA Edition, enabling cheats / running commands does NOT disable advancements. No legality or online-ban risk: these are built-in features, not third-party hacks. Commands like /kill, /fill, and /clone are powerful and can destroy builds or items instantly with no undo, so test on a backup world first. Internal gamerule names changed to snake_case in recent Java versions, but the classic camelCase names (e.g. keepInventory) are still accepted; Bedrock treats gamerule names as case-insensitive (e.g. keepinventory).
How to enter cheats // PC
Java: When creating a new world, open 'More World Options...' / 'Game Rules' and turn on 'Allow Cheats: ON' (cheats can also be force-enabled mid-game per session via 'Open to LAN' > Allow Cheats: ON). Bedrock (Windows): when creating/editing a world, open Settings > Cheats and turn on 'Activate Cheats'. To enter commands, press T or / to open the chat box, type the command starting with /, then press Enter. Command blocks can be obtained with /give @s command_block and run commands when powered by redstone.
Game Mode & Difficulty05 CODES
- Switch to Creative mode (fly, unlimited blocks, no damage)Modes: survival, creative, adventure, spectator. Java also accepts numbers (0=survival, 1=creative, 2=adventure, 3=spectator) and abbreviations like /gamemode c. Add a target at the end, e.g. /gamemode creative @a.
/gamemode creative - Switch to Survival mode
/gamemode survival - Switch to Adventure mode
/gamemode adventure - Switch to Spectator mode (Java; Bedrock has it too in recent versions)
/gamemode spectator - Set world difficultyValues: peaceful, easy, normal, hard. Peaceful stops hostile mob spawns and slowly heals you.
/difficulty peaceful
Items & Inventory05 CODES
- Give yourself an itemJava syntax: /give <targets> <item> [count] [dataTag]. Bedrock: /give <player> <itemName> [amount] [data] [components]. Item names use the minecraft: namespace (the prefix is optional when typing). Example: /give @s diamond_sword 1. Use @s for yourself, @p nearest player, @a all players.
/give @s <item> [amount] - Give a stack of diamonds
/give @s diamond 64 - Give a command block (to run commands via redstone)Requires cheats/op. Placing and editing command blocks lets you run any command automatically.
/give @s command_block - Add experience points or levelsJava: /xp add <targets> <amount> [points|levels] or /xp set ... ; /experience is an alias. Bedrock: /xp <amount> <player> (positive to add). Use 'levels' to add full XP levels.
/xp add @s 1000 points - Enchant the held item / a target's itemExample: /enchant @s sharpness 5. The target must be holding a compatible item. Java validates max levels unless used carefully; works on the item in the main hand.
/enchant @s <enchantment> [level]
Teleportation & World Navigation04 CODES
- Teleport yourself to coordinates/teleport is the full form, /tp is the alias. Use ~ for relative coordinates (e.g. /tp @s ~ ~10 ~ to rise 10 blocks). You can also teleport to a player: /tp @s <playername>.
/tp @s <x> <y> <z> - Teleport one player/entity to anotherExample: /tp Steve Alex teleports Steve to Alex.
/tp <target> <destinationPlayer> - Locate the nearest structureJava (1.19+): /locate structure|biome|poi <id>, e.g. /locate structure minecraft:village. Older/Bedrock: /locate <feature>. Returns coordinates to the nearest match.
/locate structure <structure> - Display the world seedPrints the numeric seed of the current world to chat.
/seed
Time & Weather04 CODES
- Set time to dayAccepts: day, noon, night, midnight, sunrise, sunset, or a tick number (0-24000). /time add <ticks> advances time; /time query gives the current value.
/time set day - Set time to night
/time set night - Clear the weatherOptions: clear, rain, thunder. Java/Bedrock accept an optional duration in seconds, e.g. /weather clear 1000000.
/weather clear - Start rain / thunderstorm
/weather thunder
Status Effects (Potion Effects)03 CODES
- Give a status effect (potions without items)Java uses /effect give <targets> <effect> ...; Bedrock uses /effect <player> <effect> ... Amplifier is 0-indexed (0 = level I, 1 = level II). Common effects: speed, haste, strength, jump_boost, regeneration, water_breathing, night_vision, invisibility, fire_resistance, resistance, levitation, slow_falling, saturation, glowing.
/effect give @s <effect> [seconds] [amplifier] [hideParticles] - Infinite Night VisionUse a huge duration for near-infinite. In recent Java versions you can use the literal 'infinite' as the duration: /effect give @s night_vision infinite.
/effect give @s night_vision 999999 0 true - Clear all status effectsJava: /effect clear <targets> [effect]. Bedrock: /effect <player> clear.
/effect clear @s
Entities & Mobs02 CODES
- Summon an entity (mob, item, etc.)Example: /summon zombie ~ ~ ~. Java supports an extra NBT tag argument for custom data; Bedrock supports optional spawnEvent/nameTag arguments. Entity ids use the minecraft: namespace.
/summon <entity> [x] [y] [z] - Kill entities / yourself/kill with no target kills the executing player. /kill @e[type=zombie] kills all zombies; /kill @e (Java) can clear all entities including dropped items, so use carefully.
/kill [target]
Building & World Editing03 CODES
- Place a single block at a positionExample: /setblock ~ ~ ~ stone. Optional mode in Java: replace, destroy, keep.
/setblock <x> <y> <z> <block> - Fill a region with a blockFills the cuboid between the two corners. Optional modes: replace, hollow, outline, keep, destroy (Java) / similar on Bedrock. Large fills can lag or overwrite builds with no undo.
/fill <x1> <y1> <z1> <x2> <y2> <z2> <block> - Clone (copy) a region to another locationJava: /clone <begin> <end> <destination> [maskMode] [cloneMode]. Bedrock similar. Destination is the lowest corner where the copy is pasted.
/clone <x1> <y1> <z1> <x2> <y2> <z2> <destX> <destY> <destZ>
Game Rules12 CODES
- Keep your inventory when you dieJava uses camelCase keepInventory; Bedrock is case-insensitive (keepinventory). Set false to drop items on death (default).
/gamerule keepInventory true - Stop the day/night cycle (freeze time of day)When false, time stays fixed at whatever it is when you run it (combine with /time set day).
/gamerule doDaylightCycle false - Disable mob griefing (mobs can't destroy/trample blocks)Stops creeper terrain damage, enderman block-stealing, farm trampling, etc.
/gamerule mobGriefing false - Stop fire from spreadingFire still burns but won't spread to or destroy nearby blocks.
/gamerule doFireTick false - Change random tick speed (crop/plant growth rate)Integer rule. Default is 3 in Java, 1 in Bedrock; max 4096. Higher = faster crop growth, leaf decay, fire burnout. Very high values cause severe lag.
/gamerule randomTickSpeed 100 - Disable mob spawningStops natural mob spawns (already-spawned mobs remain).
/gamerule doMobSpawning false - Stop the weather cycleFreezes current weather; pair with /weather clear.
/gamerule doWeatherCycle false - Respawn instantly without the death screenSkips the 'You Died' screen and respawns immediately.
/gamerule doImmediateRespawn true - Turn off natural health regenerationPlayers no longer heal from a full hunger bar (must use food/effects/golden apples).
/gamerule naturalRegeneration false - Show/hide coordinates (Bedrock)Bedrock-specific HUD coordinate display. In Java, the F3 debug screen shows coordinates instead.
/gamerule showcoordinates true - Toggle PvP (players damaging each other)Note: in Java this rule is primarily a Bedrock/server-style toggle; standard Java servers use server.properties pvp. On Bedrock, /gamerule pvp false disables player-vs-player damage.
/gamerule pvp false - Hide command output / feedback in chatcommandBlockOutput suppresses command-block messages; sendCommandFeedback (Java) / sendcommandfeedback (Bedrock) suppresses chat feedback from player-run commands.
/gamerule commandBlockOutput false
On the full ID list
Minecraft does not have a fixed list of cheat codes; it has a large command set plus thousands of item IDs, block IDs, entity IDs, enchantment IDs, effect IDs, and dozens of game rules. This entry captures every major command and its Java vs Bedrock syntax, the most-used variants, and the most-searched game rules, rather than enumerating every ID. For the authoritative, complete reference of all commands, item/block/entity IDs, and game rules, see the official Minecraft Wiki command list at https://minecraft.wiki/w/Commands and the official Bedrock command docs at https://learn.microsoft.com/en-us/minecraft/creator/commands/. For exhaustive copy-paste item/give IDs, DigMinecraft maintains per-version ID lists at https://www.digminecraft.com/lists/item_id_list_pc.php (Java) and https://www.digminecraft.com/lists/item_id_list_pe.php (Bedrock).
FAQ // Straight answers
How do you enable cheats in Minecraft?
When creating a world, turn on the "Allow Cheats" toggle in the world settings. In an existing single-player world you can usually open it to LAN and enable cheats from the pause menu. Once cheats are on, type commands into the chat box starting with a forward slash (/).
Do cheats disable achievements in Minecraft?
Yes. Enabling cheats permanently disables achievements and trophies for that world, even if you later turn cheats back off. If you want achievements, play with cheats disabled or create a separate world for experimenting with commands.
Is there a money cheat in Minecraft?
No. Vanilla Minecraft has no currency system, so there is no money cheat. Players use commands like the give command to grant items directly, and any in-game economy comes from servers, plugins, or add-ons rather than a built-in money cheat.
How do you give yourself items in Minecraft?
Use the give command in the chat console, specifying the player name and the item identifier (and optionally a quantity). Cheats must be enabled first. In Creative mode you can also pull items directly from the creative inventory without any command.
Do Minecraft cheats work on Java and Bedrock?
Both editions support commands, but the syntax and some command names differ. Java Edition and Bedrock Edition (Windows, consoles, and mobile) share many core commands like gamemode, give, and teleport, while certain commands, targets, and arguments are edition-specific.
How do you turn on creative mode with a command?
With cheats enabled, use the gamemode command in chat and set it to creative; you can switch back to survival, adventure, or spectator the same way. Creative mode gives flight, unlimited blocks, and no damage, which is why cheats must be on to change it via command.
Sources // cross-checked
- Commands - Minecraft Wiki (official)
- Game rule - Minecraft Wiki (official)
- gamerule Command - Microsoft Learn (official Bedrock docs)
- How to Use the Effect Command in Minecraft - DigMinecraft
- How to Use the Give Command in Minecraft - DigMinecraft
- How to Enable Cheats in Minecraft (Bedrock & Java) - Beebom
- How to Use Commands in Minecraft - Minecraft.net (official)
More cheat guides
- Age of Empires II: Definitive Edition Cheats
- ARK: Survival Ascended / Evolved Cheats
- Baldur's Gate 3 Cheats
- Cyberpunk 2077 Cheats
- DOOM (1993) and DOOM II Cheats
- Fallout 4 Cheats
- Grand Theft Auto: San Andreas Cheats
- Grand Theft Auto: Vice City Cheats
- Mortal Kombat 1 (2023) and Mortal Kombat 11 Cheats
- NBA 2K26 Cheats
- Pokemon GBA era (Emerald, FireRed/LeafGreen, Ruby/Sapphire) Cheats
- Red Dead Redemption 2 Cheats
- The Elder Scrolls V: Skyrim Cheats
- Stardew Valley Cheats
- The Sims 3 Cheats
- The Sims 4 Cheats
- The Witcher 3: Wild Hunt Cheats
- WWE 2K26 Cheats
Getting ready for GTA 6?
Launch day is Thursday, November 19, 2026. Run the PS5 Readiness Check and browse every cheat-code guide.