News
Game
Guides
Downloads
Versions
/difficulty
COMMANDS WORLD & RULES CHEATS · LEVEL 2 Added in 1.14 or earlier

/difficulty command in Minecraft

The /difficulty command shows the current difficulty or switches it between peaceful, easy, normal and hard. The change is immediate and applies to the whole world, which makes it handy to clear hostile mobs for a while or to test a farm on Hard.

Syntax

/difficulty
/difficulty easy
/difficulty hard
/difficulty normal
/difficulty peaceful

Examples

Check the difficulty

/difficulty

Shows "The difficulty is ..." without changing anything.

Java 26.3

Switch to Hard

/difficulty hard

Hunger can now kill and zombies break wooden doors.

Java 26.3

Clear hostile mobs

/difficulty peaceful

Hostile mobs disappear and stop spawning until you raise the difficulty again.

Java 26.3

Back to Normal

/difficulty normal

The standard difficulty: monsters spawn, and hunger stops at half a heart.

Java 26.3
Build your command

Fill in the fields, then copy the command.

Command generator

What changes between levels

  • peaceful: hostile mobs vanish and no longer spawn, health regenerates and hunger does not drop.
  • easy: hunger can lower your health, but never below 5 hearts.
  • normal: hunger stops at half a heart.
  • hard: hunger can kill, and a Zombie can break wooden doors.

Mobs also deal more damage at each level. Hardcore is not an option of this command: it is a world mode chosen at creation, so /difficulty only knows the four values above.

Common errors

"The difficulty did not change; it is already set to ..." means the world was already at that level. In Peaceful, /summon refuses monsters with "Monsters cannot be summoned in Peaceful difficulty", so switch back before testing a boss or a spawner.

Alternatives

Peaceful also stops hunger, which is not always what you want. To keep a normal survival game without new monsters, set spawn_monsters to false with /gamerule. On a dedicated server, the starting value comes from difficulty in server.properties, and /difficulty changes it while the server runs. The difficulty is shared by everyone: there is no per-player setting, so agree on it before you change it on a shared world.

✓ Checked in Java Edition 26.3 · updated 2 November 2026

/difficulty: FAQ

Does /difficulty peaceful remove hostile mobs right away?

Yes. Hostile mobs disappear as soon as Peaceful is set, and they stop spawning until you raise the difficulty again.

Can each player have their own difficulty?

No. There is one difficulty per world or server, shared by all players. On a server, operators change it for everyone.

How do I use /difficulty?

Type it in the chat with cheats on: /difficulty.

Who can use /difficulty?

Cheats on, or operator level 2.

Related commands