How to make custom items with /give: names, lore, and unbreakable
8 min read
A custom item is just a normal item with extra data attached: a display name, lore lines, an unbreakable flag, and enchantments. The only real difficulty is that Minecraft Java 1.20.5 moved this data out of legacy NBT tags and into item components, so the exact syntax depends on your version. NBTForge builds the item visually and prints the correct string for whichever version you select.
Ergebnis
One /give command that produces a renamed, lore-tagged, unbreakable, optionally enchanted item on the version you are targeting.
Empfohlener Weg
- Open the Give module and choose the base item (for example diamond_sword or netherite_helmet).
- Set the Edition and Version to match the world that will run the command, because item components (1.20.5+) and legacy NBT (1.20.4 and older) are not interchangeable.
- Add a custom name, then turn off italics if you do not want the default italic styling.
- Add lore lines, an unbreakable flag, and any enchantments, checking the live output after each change.
- Copy the finished command from Output and test it in a creative world before shipping it in a map or datapack.
Legacy NBT vs item components
On Java 1.20.4 and older, custom item data lives in an NBT compound after the item id: names and lore go inside display, and there are top-level Unbreakable and Enchantments tags. A full example is /give @p diamond_sword{display:{Name:'{"text":"Excalibur"}'},Unbreakable:1,Enchantments:[{id:"sharpness",lvl:5}]}.
On Java 1.20.5 and newer the same item is written with square-bracket components: /give @p diamond_sword[custom_name='{"text":"Excalibur","italic":false}',unbreakable={},enchantments={levels:{sharpness:5}}]. In 1.21.5+ the enchantments wrapper was simplified to enchantments={sharpness:5}. Pick the version first and let the generator handle the exact brackets.
- Use the display compound and Unbreakable:1 for 1.20.4 and older.
- Use custom_name, lore, unbreakable={}, and enchantments components for 1.20.5+.
- The item id stays the same across both styles — only the data wrapper changes.
Names and lore that are not italic
Custom names and lore are JSON text components, so they accept color, bold, and other formatting. By default Minecraft renders custom names in italics; set "italic":false inside the text component to get a clean, upright name.
Lore is a list of separate text components, one per line. Keep each line short, set italic and color explicitly, and rebuild the text in the visual editor rather than hand-editing quote characters, which is where most long give commands break.
- Add "italic":false to remove the default italic styling.
- Use "color":"gold" or a hex value like "#55FFFF" for colored text.
- Each lore entry is its own line — add several for a multi-line description.
Unbreakable, glint, and enchantments
Unbreakable items never lose durability. The /enchant command refuses invalid or over-max enchantments, but /give writes enchantment data directly, so it is how people create Sharpness far above level 5. Overleveled enchantments are covered in the dedicated enchant guide.
If you want the enchanted shimmer without any real enchantment, 1.20.5+ has an enchantment_glint_override=true component. On older versions the usual trick is a hidden or dummy enchantment. Keep an eye on output warnings when you move a command between versions.
Ship the copied artifact
Use this guide to produce the artifact a player or map maker will actually run: a copied command, ordered Project pack, or datapack resource. The final review should happen on that copied output, not only on the editable builder state.
When the workflow is version-sensitive, label the target version beside the command. When it uses selectors, scoreboards, bossbars, tags, loot tables, or project order, test those dependencies in a clean world before publishing the setup.
- Copy from Output for one command and from Project for ordered packs.
- Keep Java, Bedrock, and snapshot variants separate.
- Test destructive selectors with harmless output first.
- Update related presets when the guide becomes the canonical workflow.
Verwandte Guides und Presets
FAQ
Why does my /give command work on one version but not another?
Java 1.20.5 replaced legacy item NBT with item components. A command written with {display:{Name:...}} fails on 1.20.5+, and a command written with [custom_name=...] fails on 1.20.4 and older. Set the version first.
How do I stop the custom name from being italic?
Add "italic":false inside the name text component, for example custom_name='{"text":"Excalibur","italic":false}'. The same works for each lore line.
How do I add multiple lore lines?
Lore is a list. Add one text component per line: lore=['{"text":"Line one"}','{"text":"Line two"}']. In legacy NBT the equivalent is Lore inside the display compound.
Can I make any item unbreakable?
Yes. Any item with durability can carry the unbreakable data. Use unbreakable={} (1.20.5+) or Unbreakable:1 (1.20.4 and older). Items without durability simply ignore it.
Why does the give command fail on my server?
Common causes are a version mismatch, an item id that is not prefixed correctly, or a name/lore JSON string that is double-escaped. Rebuild the item in the visual editor so the quoting stays valid.
When should this guide become a Project pack?
Use Project when the workflow needs more than one command, has setup and cleanup order, or must be edited again after testing. One-off commands can stay in Output.