Ad · Sztuka HarmoniiAdConsultations and ADHD assessment in English · −50% off your first visit · Sztuka HarmoniiPsychologist in English · −50% · Sztuka HarmoniiBook
Discord
Ad · Sztuka HarmoniiConsultations and ADHD assessment in EnglishPsychologist in EnglishIn Gdańsk, Gdynia or online.−50%off your first visitBook an appointmentBook

/give command

The /give command adds any item to a player's inventory. You can set the amount, NBT data (Java) and components (1.20.5+). It's the go-to cheat for testing and administration.

Items OP 2 since Beta 1.3

Syntax

Java and Bedrock Edition

/give <player> <item> [amount]

Parameters in <angle brackets> are required. Parameters in [square brackets] are optional.

Parameters

Parameter Type Required Description
player selector/player Yes The player who receives the item. The @a selector gives the item to every player.
item item ID Yes The item's ID in the minecraft: namespace, for example minecraft:diamond_sword or minecraft:netherite_pickaxe.
amount number (1-6,400) No The number of items. Defaults to 1. The maximum is 6,400 (100 stacks of 64). Items that don't stack each go into a separate slot.

Usage examples

Example 1
/give @p diamond 64

Gives the nearest player a full stack (64) of diamonds.

Example 2
/give @a minecraft:golden_apple 16

Gives each player on the server 16 golden apples.

Example 3 Java
/give @p diamond_sword[enchantments={levels:{"sharpness":5,"unbreaking":3,"mending":1}}] 1

Gives a diamond sword with Sharpness V, Unbreaking III and Mending (1.20.5+ syntax).

Example 4 Java
/give @p netherite_pickaxe[enchantments={levels:{"efficiency":5,"fortune":3}}]

Gives a netherite pickaxe with Efficiency V and Fortune III (1.20.5+ syntax).

Example 5
/give @s command_block 1

Gives you a command block. Handy, because you won't find command blocks in the Creative inventory.

Tips and tricks

*

Since Java 1.20.5, NBT data has been replaced by components. Instead of {Enchantments:[...]}, you write [enchantments={...}]. The old NBT syntax doesn't work in newer versions.

*

Bedrock Edition doesn't support NBT data or Java's item components in /give.

*

If the player's inventory is full, the item drops on the ground next to them.

*

Use /give @p air 1 to get... nothing. It doesn't throw an error, though, which comes in handy when testing command blocks.

Related commands

Frequently asked questions

How do you use the /give command in Minecraft?

Open the chat with the T or / key and type the command using this syntax: /give <player> <item> [amount]. The /give command adds any item to a player's inventory. You can set the amount, NBT data (Java) and components (1.20.5+). It's the go-to cheat for testing and administration.

What permissions does /give require?

The /give command requires permission level 2: Operator (OP 2). In singleplayer with cheats turned on, you automatically have full permissions. On a multiplayer server, you need operator status, which is granted with the /op command.

Does /give work in Bedrock Edition?

Yes, the /give command works in both Java Edition and Bedrock Edition, with similar syntax.