Skip to content
/SLASHPLAY

How to give yourself items in Minecraft

Type /give @p minecraft:diamond_sword 1 in chat as an operator, or give Steve minecraft:oak_log 64 in the server console to give a player items.

give

Puts items into players' inventories, with an optional count and item components such as enchantments or names.

/give <targets> <item> [<count>]

Examples

/give @p minecraft:diamond_sword 1

Gives the nearest player a diamond sword.

/give Steve minecraft:oak_log 64

Gives Steve a full stack of oak logs.

give @a minecraft:golden_apple 3

From the server console, without the slash.

Arguments

targetsRequired
Player name or selector, such as @p or @a.
itemRequired
Item ID, optionally with components in [ ].
countOptional
How many to give, at least 1. Defaults to 1.

What it does

The item goes straight into the inventory; anything that does not fit drops at the player's feet. The minecraft: prefix is optional, and you can add item components in square brackets after the ID to set custom names, enchantments and similar data. A count larger than one stack is split into several stacks.

Good to know

  • Needs operator permission level 2.
  • In the console there is no nearest player, so use a name or @a.

Run it on your server

On a SLASHPLAY server, type it in the Console tab without the leading slash; in game, operators type it in chat with the slash. New to this? Start a Minecraft server first.

Your own
Minecraft server.

From $0.03 an hour, only while it runs. New accounts get 6 free tokens.