Published by
MC Commander operator
Last reviewed
Verification status
Version-specific regression tests for major generators, JavaScript/PHP syntax, and internal HTML references were checked. Not every version/output combination has been executed in Minecraft itself. Editorial policy

Copy-ready starting examples

/give @p minecraft:diamond_sword 1
/give @p minecraft:diamond_sword[minecraft:custom_name={"text":"Azure Sword","color":"aqua"}] 1

How to build it

  1. Select the target and item in the Give generator.
  2. Add a custom name, lore, enchantments or unbreakable data.
  3. Send the output to the syntax checker and test the shortest working form first.

Common mistakes

Edition and version notes

Java 1.21.5+ stores text components directly. Java 1.20.5–1.21.4 keeps the earlier string-wrapped text form, but attribute modifiers differ across 1.20.5–1.20.6, 1.21–1.21.1, and 1.21.2–1.21.4. Java 1.20.4 and earlier use legacy NBT, while 1.12.2 also uses the older Give argument order and numeric enchantment IDs. Bedrock cannot express every Java custom item feature in one Give command.

Open generator

Isolate the item customization that fails

First run /give @p minecraft:diamond_sword 1 to confirm item ID and permission. Then add only a custom name; confirm the result before adding enchantments or unbreakable data. Java Edition 1.20.5+ uses item components and cannot directly reuse older NBT item examples. Bedrock does not accept Java item component syntax either.

If the base command works but the customized one fails, do not change the target selector or ID at the same time. Compare the output with the selected edition and remove the last option added. This is usually faster than troubleshooting a long command all at once.

Related pages

← Minecraft Command Solutions