How to kill all entities in Minecraft 1.19 update

Players can easily kill all loaded entities at once (Image via Minecraft 1.19 update)
Players can easily kill all loaded entities at once (Image via Minecraft 1.19 update)

If players want to kill any entity in the Minecraft 1.19 update, they usually use different in-game weapons to do so. However, the age-old sandbox game has another way through which nearly all entities in a particular area can be killed instantly at once. This can only be achieved by executing a command in the game.

Commands are certain lines of code that players can insert in the game to execute all kinds of things. From generating a structure to changing the weather and time, almost everything can be done by commands. However, in order to use them, the world must have cheats enabled on it. Using this feature, players can also kill nearly all entities that are loaded in chunks with one line.


How to enable commands and kill all entities in Minecraft 1.19 update

How to enable commands in a world

Open to LAN temporarily allows cheats so that players can enter commands (Image via Minecraft 1.19 update)
Open to LAN temporarily allows cheats so that players can enter commands (Image via Minecraft 1.19 update)

If players want to kill all entities in an area, they can only do so by using commands. Otherwise, players will have to manually kill every entity one by one, even in creative mode. However, not all worlds allow commands to be executed in them. To enable them, players must ensure that cheats are allowed in that particular world.

When a world is being created for the first time, the game will ask the player whether they want to allow cheats or not. These settings cannot be changed once the world has been created. However, there is a way to temporarily allow cheats in the world by opening it to LAN. In the pause menu, players will find 'Open to LAN' settings where they can toggle 'Allow cheats' and start the LAN world. This will give players permission to execute commands.


/kill command

Kill command to kill everyone including the player (Image via Minecraft 1.19 update)
Kill command to kill everyone including the player (Image via Minecraft 1.19 update)

After players are able to enter commands in the world, they can kill entities in the game and even themselves with the '/kill' command. When the kill command is normally executed, it kills the player itself. However, they can type '@e' to kill all entities that are nearby. This is the most basic way to kill everyone, including the player writing the code. The exact command line is '/kill @e'.

The number of entities that are affected by the command depends on the render and simulation distance. If the game loads more active chunks where the mobs spawn, this command will affect them as well.

Kill command to kill everyone but the player (Image via Minecraft 1.19 update)
Kill command to kill everyone but the player (Image via Minecraft 1.19 update)

Players can also extend the command and exclude themselves from dying as well. For this, the command line will be '/kill @e[type=!minecraft:player]'. Moreover, players can also use this to exclude any type of mob. With another line, players can even set the distance till which the command will work. For example, players can type '/kill @e[distance=10]' to kill anyone that is within a 10-block radius.

Quick Links