Minecraft /give Command Generator

Build a /give command with enchantments, a custom name, lore and count, for current data-component versions or older NBT.

Enchantments
Command
/give @p minecraft:diamond_sword 1

Paste into chat (with op) or a command block. Drop the leading / in command blocks.

Build a custom server experience
Command blocks, datapacks and plugins run best on a server that's always up. Host on FadeHost: instant setup, full file access. From $2.50/mo.
Start free trial →

Components vs NBT

Up to 1.20.4 items carried data in an NBT tag, e.g. {Enchantments:[...]}. From 1.20.5 that became data components in square brackets, e.g. [enchantments={...}]. Pick the format that matches your server's version.

FAQ

How do I use a /give command?

Copy the generated command and paste it into the in-game chat (you need operator permissions or cheats enabled), or into a command block without the leading slash. Press enter and the item appears in the target’s inventory.

What target selectors can I use?

@p (nearest player), @a (all players), @s (yourself / the command runner), @r (random player), @e (entities), or an exact username. @s is handy in command blocks.

Why are there two command formats?

Minecraft 1.20.5 replaced item NBT tags with data components. Use “1.20.5+ (components)” for current versions and “1.13 to 1.20.4 (NBT)” for older ones. They produce different but equivalent syntax.

How do I add enchantments above the normal maximum?

Set any level you want in the enchantment level box. Commands aren’t limited to the survival maximum, so Sharpness 1000 is valid. Very high levels can look odd or be capped by some servers.

Can I add a custom name and lore?

Yes. The custom name shows as the item’s title (with italics disabled to look clean), and each lore line appears beneath it. Use color/format with section signs in newer versions, or our MOTD generator for the codes.

Does this work on Bukkit / Spigot / Paper servers?

Yes. /give is vanilla and works on Paper, Spigot, Purpur and Fabric. The component vs NBT choice depends on the server’s Minecraft version, not the software.