/give
Gives one or more items to one or more players. The item can include NBT data via component syntax.
Syntax
/give <targets> <item> [<count>]Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| targets | entity | Required | The player(s) to give the item to. Must resolve to players. |
| item | item_stack | Required | The item to give. Supports item IDs and component syntax (e.g. diamond_sword[damage=10]). |
| count | integer | Optional | The number of items to give (1-6400). Defaults to 1. Amounts over a single stack are split across multiple stacks. |
Examples
/give @p diamond 64Gives the nearest player a full stack of 64 diamonds.
/give @a minecraft:written_book[written_book_content={title:"Rules",author:"Server",pages:['"Welcome to Astroworld!"']}] 1Gives every player a written book with custom content.
/give @s netherite_sword[enchantments={levels:{sharpness:5}}] 1Gives yourself a netherite sword enchanted with Sharpness V using component syntax.
Common Mistakes
- Using a count greater than 6400, the maximum per /give invocation is 6400.
- Targeting entities that are not players, /give can only target player entities.
Notes
In 1.20.5+ the NBT tag syntax was replaced with component syntax using square brackets. Items exceeding the max stack size are distributed across multiple inventory slots.
Related Commands
Need a Minecraft server?
Try these commands on Astroworld or host your own server.
Try Astroworld Hosting