Generate and Drop Loot Table Items
The /loot command in Minecraft Bedrock Edition drops items from a chosen loot table directly into the world or into an inventory. You can generate items from a specific loot table path, simulate killing an entity, or simulate mining a block at specific coordinates.
Map makers and server admins use this command to reward players with randomized chest loot, refill containers automatically, or test custom loot drops using the tool currently held in a hand.
/loot spawn <position: x y z> loot <loot_table: string> [<tool>|mainhand|offhand: Tool]Spawn loot into hand
/loot spawn <position: x y z> kill <entity: target> [<tool>|mainhand|offhand: Tool]Spawn loot from position, kill entity with tool
/loot spawn <position: x y z> mine <TargetBlockPosition: x y z> [<tool>|mainhand|offhand: Tool]Give loot to player, looting with tool
/loot give <players: target> loot <loot_table: string> [<tool>|mainhand|offhand: Tool]Give loot to player, killing entity using tool
/loot give <players: target> kill <entity: target> [<tool>|mainhand|offhand: Tool]Give loot to player, mining a block using tool
/loot give <players: target> mine <TargetBlockPosition: x y z> [<tool>|mainhand|offhand: Tool]Insert loot from position, looting with tool
/loot insert <position: x y z> loot <loot_table: string> [<tool>|mainhand|offhand: Tool]Insert loot from position, killing entity with tool
/loot insert <position: x y z> kill <entity: target> [<tool>|mainhand|offhand: Tool]Insert loot from position, mining a block with tool
/loot insert <position: x y z> mine <TargetBlockPosition: x y z> [<tool>|mainhand|offhand: Tool]Replace loot, slot, count, looting with tool
/loot replace entity <entity: target> <slotType: EntityEquipmentSlot> <slotId: int> <count: int> loot <loot_table: string> [<tool>|mainhand|offhand: Tool]Replace loot, slot, looting with tool
/loot replace entity <entity: target> <slotType: EntityEquipmentSlot> <slotId: int> loot <loot_table: string> [<tool>|mainhand|offhand: Tool]Replace loot, slot, count, killing entity with tool
/loot replace entity <entity: target> <slotType: EntityEquipmentSlot> <slotId: int> <count: int> kill <entity: target> [<tool>|mainhand|offhand: Tool]Replace loot, slot, killing entity with tool
/loot replace entity <entity: target> <slotType: EntityEquipmentSlot> <slotId: int> kill <entity: target> [<tool>|mainhand|offhand: Tool]Replace loot, slot, count, mining a block with tool
/loot replace entity <entity: target> <slotType: EntityEquipmentSlot> <slotId: int> <count: int> mine <TargetBlockPosition: x y z> [<tool>|mainhand|offhand: Tool]Replace loot, slot, mining a block with tool
/loot replace entity <entity: target> <slotType: EntityEquipmentSlot> <slotId: int> mine <TargetBlockPosition: x y z> [<tool>|mainhand|offhand: Tool]Replace loot, slot, count, looting with a tool
/loot replace block <position: x y z> slot.container <slotId: int> <count: int> loot <loot_table: string> [<tool>|mainhand|offhand: Tool]Replace loot, slot, looting with `tool`
/loot replace block <position: x y z> slot.container <slotId: int> loot <loot_table: string> [<tool>|mainhand|offhand: Tool]Replace loot slot, count, killing `entity` with a tool
/loot replace block <position: x y z> slot.container <slotId: int> <count: int> kill <entity: target> [<tool>|mainhand|offhand: Tool]Replace loot from block, killing `entity` with tool
/loot replace block <position: x y z> slot.container <slotId: int> kill <entity: target> [<tool>|mainhand|offhand: Tool]Replace loot slot, count, mining a block with a tool
/loot replace block <position: x y z> slot.container <slotId: int> <count: int> mine <TargetBlockPosition: x y z> [<tool>|mainhand|offhand: Tool]Replace loot from block, mining a block with tool.
| Argument | Type | What it means |
|---|---|---|
<tool>|mainhand|offhand | Tool | Specifies the hand holding the tool |
count | int | An integer that defines the total number of inventory or container slots to fill. |
entity | target | Specifies the target entity that either receives the items or acts as the source of the killed entity loot. |
loot_table | string | The string file path to the loot table you want to generate items from. |
players | target | A target selector or player name specifying who will receive the generated loot. |
position: x y z | position | The x, y, and z coordinates where loot is spawned in the world or where a target container block is located. |
slotId | int | An integer that chooses the specific starting slot number inside an entity or block inventory. |
slotType | EntityEquipmentSlot | The specific equipment or inventory slot category on an entity to replace items in. |
TargetBlockPosition: x y z | position | The x, y, and z coordinates of the block to simulate mining for drops. |
/loot give @p loot "loot_tables/chests/simple_dungeon.json"Gives the nearest player randomized items from the simple dungeon chest loot table.
/loot spawn ~ ~1 ~ loot "loot_tables/chests/desert_pyramid.json"Spawns loot from the desert pyramid chest table into the world one block above your current position.
/loot give @a kill @e[type=zombie,c=1] mainhandGives all players the loot that would drop from killing one zombie using the tool in the executor's main hand.
/loot give @s mine 100 64 200 mainhandGives the player running the command the drops from mining the block at 100 64 200 with their mainhand tool.
/loot insert 12 65 -30 loot "loot_tables/chests/abandoned_mineshaft.json"Inserts items from the abandoned mineshaft loot table directly into a container at coordinates 12 65 -30.
/loot insert -45 70 110 kill @e[type=skeleton,c=1] offhandInserts the drops from killing one skeleton with your offhand item into a container at -45 70 110.
/loot replace block 0 60 0 slot.container 0 5 loot "loot_tables/chests/end_city_treasure.json"Replaces 5 slots starting at slot 0 in the container at 0 60 0 with End City treasure loot.
/loot replace entity @r slot.hotbar 0 2 mine ~ ~-1 ~ mainhandReplaces 2 hotbar slots starting at slot 0 on a random player with drops from mining the block directly below.
In Minecraft Java Edition, the /loot command includes a fish source option (such as /loot give <players> fish <loot_table> <pos> [tool|mainhand|offhand]) to simulate fishing at a specific position, which is not part of the Bedrock Edition syntax.
You must have cheats enabled in your world and hold the Game Directors permission level to run the /loot command.
No, the kill argument only reads the target entity to calculate what loot it would drop and leaves the entity unharmed.
The insert option places generated loot into available space inside a container, while replace block overwrites specific slot numbers that you choose with slotId and count.