Minecraft Give Command Guide: Item IDs, Syntax & Recipes

How Minecraft item IDs work with the /give command: namespaced IDs after The Flattening, the 1.20.5+ component syntax, copy-ready recipes for enchanted and custom items, and fixes for every common parse error.

Updated: · Covers Java Edition 1.21.5 through 26.2

Java 1.21.5–26.2 covered 1,538 cataloged item IDs No numeric IDs since 1.13 Component syntax since 1.20.5 Cheats or OP required 100-stack cap per /give

Open the Give Command Generator →   Jump to Recipes ↓

Fast Answer: The Current /give Syntax

/give <targets> <item> [<count>]
/give @s minecraft:diamond_sword 1

This is the complete grammar for Java Edition 1.21.5 through 26.2 (the current stable release). <targets> is a player name or selector such as @s, <item> is a namespaced item ID like minecraft:diamond_sword optionally followed by data components in square brackets, and <count> is an optional quantity. Cheats must be enabled: toggle Allow Cheats in singleplayer, hold operator status on a server, or run the command from a command block.

Every example on this page is labeled with the versions it parses on. Commands using square-bracket item components require Java 1.20.5 or later; text components written in inline SNBT form (custom_name={text:"Name"}) require 1.21.5 or later. Old commands copied from pre-1.20.5 tutorials will fail to parse on any current version.

Namespaced Item IDs Explained

Every block, item, entity, status effect, and enchantment in modern Minecraft is identified by a namespaced ID (officially called a resource location) in the format namespace:path — for example minecraft:diamond_sword. The namespace says which content pack an object comes from: vanilla content lives in the reserved minecraft namespace, while mods and data packs use their own, so mymod:gem_sword can never collide with a future vanilla item.

Only lowercase letters, digits, underscores, hyphens, and dots are valid characters. Diamond_Sword will not parse; diamond_sword will. In commands the minecraft: prefix is optional for vanilla content — the game resolves a bare diamond to minecraft:diamond automatically — but writing the full namespaced form is recommended, and the prefix is mandatory when referencing modded or data-pack content.

To find the ID of an item you are holding in Java Edition, press F3+H to enable Advanced Tooltips and hover over it. Tab-completion in the chat line also enumerates every valid ID as you type. For the full registry, browse this site's Minecraft item ID list and block IDs. Server owners can also dump the machine-readable canonical registry with the --reports flag (registries.json, items.json) — the same source data-generation tools rely on.

Why numeric IDs died: The Flattening (1.13)

Before Java Edition 1.13, blocks used numeric IDs from 0–255 plus a 4-bit metadata value, and items used numeric IDs starting at 256 — the diamond sword was item 276, and /give @p 276 1 0 was a valid command. The scheme was hard-capped at 256 block IDs and forced completely different blocks (all six plank types, all sixteen wool colors) to share one ID distinguished only by metadata.

In snapshot 17w47a for 1.13, Mojang executed "The Flattening": metadata was replaced by explicit block states, and every variant received its own namespaced ID — wool with data value 14 became minecraft:red_wool, stone:1 became minecraft:granite. From 1.13 onward, namespaced identifiers are the only accepted form and numeric IDs were removed entirely. If an old tutorial hands you a number, translate it with this site's legacy 1.12 ID list.

/give Syntax Evolution: NBT Braces → Data Components

Item customization in /give has been through three breaking eras. If a command from an old tutorial fails to parse, this table is almost certainly the reason — match the syntax to your game version.

Feature≤1.12.2 (numeric + NBT)1.13–1.20.4 (NBT)1.20.5–1.21.4 (components)1.21.5+ / 26.x (components, SNBT text)
Plain sword/give @p 276 1 0/give @s minecraft:diamond_sword/give @s minecraft:diamond_sword/give @s minecraft:diamond_sword
Sharpness V{ench:[{id:16s,lvl:5s}]}{Enchantments:[{id:"minecraft:sharpness",lvl:5s}]}[enchantments={levels:{"minecraft:sharpness":5}}][enchantments={"minecraft:sharpness":5}]
Custom name{display:{Name:"Excalibur"}}{display:{Name:'{"text":"Excalibur"}'}}[custom_name='{"text":"Excalibur"}'][custom_name={text:"Excalibur",italic:false}]
Lore{display:{Lore:["A legend"]}}{display:{Lore:['{"text":"A legend"}']}}[lore=['{"text":"A legend"}']][lore=[{text:"A legend",italic:false}]]
Unbreakable{Unbreakable:1b}{Unbreakable:1b}[unbreakable={}][unbreakable={}]
Dyed leather{display:{color:16711680}}{display:{color:16711680}}[dyed_color=16711680][dyed_color=16711680]
Player head{SkullOwner:"MHF_Sheep"}{SkullOwner:"MHF_Sheep"}[profile={name:"MHF_Sheep"}][profile={name:"MHF_Sheep"}]

1.20.5 (Armored Paws, April 2024) replaced the unstructured NBT tag on items with structured, load-time-validated data components. The old {...} syntax was removed from the item argument outright, and every legacy tag (display.Name, Enchantments, Unbreakable, SkullOwner, Potion, …) was mapped to a named component. Broken commands now fail loudly at parse time instead of silently producing broken items.

1.21.5 (Spring to Life, March 2025) added two further breaking tweaks that many "1.20.5 component" tutorials miss: text components are no longer JSON wrapped in a string (custom_name='{"text":"Name"}' became custom_name={text:"Name"}), and the enchantments map was flattened from {levels:{"minecraft:sharpness":5}} to {"minecraft:sharpness":5}.

Version numbering note: the 1.x line ended with 1.21.11 (December 2025). Releases are now year-based — 26.1 ("Tiny Takeover") and 26.2 ("Chaos Cubed") in 2026 — and the 1.21.5+ component syntax applies unchanged. Read "1.21.5+" on this page as "1.21.5 through 26.2 and later".

Bottom line: if your game is 1.21.5 or newer (including every 26.x release), only the right-hand column works — namespaced ID, square-bracket components, SNBT text. The older columns exist here purely to help you translate commands copied from outdated tutorials.

Component cheat sheet (1.21.5+ / 26.x)

ComponentPurposeMinimal example
minecraft:enchantmentsActive enchantments as an ID→level map (levels 0–255)[enchantments={"minecraft:sharpness":5}]
minecraft:stored_enchantmentsSame map, for enchanted books (inert until applied at an anvil)[stored_enchantments={"minecraft:sharpness":5}]
minecraft:custom_nameAnvil-style name (SNBT text component)[custom_name={text:"Magic Wand",italic:false}]
minecraft:loreExtra tooltip lines, a list of SNBT text components[lore=[{text:"The cake is a lie!"}]]
minecraft:unbreakableNever loses durability; empty object[unbreakable={}]
minecraft:dyed_colorRGB tint for dyeable items (int, hex, or float list)[dyed_color=0x7FFF33]
minecraft:profileSkin/name source for player heads[profile={name:"MHF_Sheep"}]
minecraft:potion_contentsPotion type, custom color, custom effects[potion_contents={potion:"minecraft:night_vision"}]
minecraft:damage / minecraft:max_damageDurability consumed / maximum durability[damage=500]
minecraft:max_stack_sizeStack size override, 1–99[max_stack_size=64]
minecraft:custom_dataFree-form data for maps and data packs[custom_data={foo:1}]
minecraft:enchantment_glint_overrideForce or suppress the enchantment glint[enchantment_glint_override=true]
minecraft:rarityName color tier[rarity=epic]

Bottom line: you rarely need more than five of these — enchantments, custom_name, lore, unbreakable, and dyed_color cover the overwhelming majority of custom-item commands. Any component you omit falls back to the item type's default, and prefixing a component name with ! removes a default you do not want.

🎮 Give Command Generator

Pick an item, choose a target, set the quantity, and get a ready-to-paste /give command with the correct component syntax. Works with every item in our catalog.

Open the Generator →
The Give Command Generator card on bestminecraftid.com: select an item, choose a target, set the quantity, and get a ready-to-paste /give command
First-hand capture of the Give Command Generator card on bestminecraftid.com, taken September 14, 2026.

Give Command Recipes (1.21.5+ / 26.x Component Syntax)

All recipes below parse on Java Edition 1.21.5 through 26.2. On 1.20.5–1.21.4, wrap text values as JSON strings instead (custom_name='{"text":"..."}'). Chat input is capped at 256 characters — anything longer belongs in a command block, which accepts tens of thousands.

Enchanted items

/give @s minecraft:netherite_sword[minecraft:enchantments={"minecraft:sharpness":5,"minecraft:mending":1,"minecraft:unbreaking":3}] 1

A netherite sword with Sharpness V, Mending, and Unbreaking III. The enchantments component is a flat map of enchantment ID to level, and levels 0–255 are accepted — sharpness:10 legitimately produces "Sharpness X", something /enchant will never do because that command enforces normal maximum levels.

/give @s minecraft:enchanted_book[minecraft:stored_enchantments={"minecraft:mending":1}] 1

An enchanted book holding Mending. Books use stored_enchantments; the enchantment stays inert until combined at an anvil.

Custom name and lore

/give @s minecraft:diamond_sword[minecraft:custom_name={text:"Excalibur",color:"gold",italic:false},minecraft:lore=[{text:"Forged in the deep",color:"gray",italic:false},{text:"Handle with care",color:"dark_gray",italic:false}]] 1

custom_name renders in italics by default (anvil-renamed style), so italic:false is the standard trick for a clean name. Lore accepts up to 256 lines. The alternative item_name component never renders italic and cannot be removed at an anvil — useful for map-making.

Dyed leather armor

/give @s minecraft:leather_chestplate[minecraft:dyed_color=16711680] 1

The color is a packed RGB integer — 16711680 is pure red. Hex (0xFF0000) and 0–1 float-list ([1.0,0.0,0.0]) forms also parse. Works on leather armor, leather horse armor, and wolf armor — anything in the #minecraft:dyeable item tag.

Player heads

/give @s minecraft:player_head[minecraft:profile={name:"MHF_Sheep"}] 1

The profile component replaces the old SkullOwner tag and accepts a player name (resolved to a skin at runtime), a UUID, or raw base64 texture properties for fully custom heads. The MHF_* accounts are Mojang's stable decoy heads, making them the safest choice for adventure maps. A name-only shorthand, profile="MHF_Sheep", also parses.

Potions

/give @s minecraft:potion[minecraft:potion_contents={potion:"minecraft:strong_strength"}] 1

Vanilla potion types are their own registry (long_night_vision, strong_leaping, luck, …).

/give @a minecraft:splash_potion[minecraft:potion_contents={custom_color:8323072,custom_effects:[{id:"minecraft:wither",amplifier:1,duration:3600}]}] 1

A fully custom brew: a recolored splash potion of Wither II for every player. Durations are in ticks (3600 ticks = 3 minutes).

Unbreakable and reshaped items

/give @s minecraft:diamond_pickaxe[minecraft:unbreakable={}] 1

The old Unbreakable:1b flag became the empty unbreakable={} component.

/give @s minecraft:totem_of_undying[minecraft:max_stack_size=64] 64

Components can do things NBT never could — here, totems that stack to 64.

/give @s minecraft:stick[minecraft:enchantment_glint_override=true]

The enchantment glint without any enchantment — handy for map rewards.

/give @s minecraft:grass_block[max_stack_size=1,max_damage=100,damage=0,tool={default_mining_speed:2,damage_per_block:1,rules:[{blocks:"#mineable/pickaxe",speed:8,correct_for_drops:true}]}] 1

An official wiki example and the extreme case: a grass block that works as a pickaxe. Components can reshape an item's stack size, durability, and tool behavior in ways NBT never could.

Bottom line: every recipe above is the same pattern — namespaced ID, then square brackets, then comma-separated component=value pairs. Start from the closest recipe, swap the ID and values, and let parse-time validation catch your mistakes; if a command grows past 256 characters, move it into a command block.

Common /give Errors and Fixes

Old NBT syntax on a new version

The single most common failure: pasting a 1.19-era command into a 1.20.5+ client. The parser rejects the {...} tag entirely because tags like Enchantments no longer exist. The fix is mechanical: move every tag into its component equivalent inside [...], as tabulated above.

A subtler variant hits players on 1.21.5+ who copy a "new" 1.20.5 tutorial: custom_name='{"text":"Name"}' now fails, because text components must be inline SNBT (custom_name={text:"Name"}).

Also check for pre-1.13 leftovers: a numeric ID or damage value such as /give @p 276 1 0 or /give @p wool 1 14 cannot work — Java has had no numeric item IDs since The Flattening, and variants like red wool are separate IDs (minecraft:red_wool).

/give @p minecraft:diamond_sword{Enchantments:[{id:"minecraft:sharpness",lvl:5s}]} 1

✗ Weak — parses only on 1.13–1.20.4. On 1.20.5 and later the curly-brace NBT tag is rejected outright.

/give @p minecraft:diamond_sword[minecraft:enchantments={"minecraft:sharpness":5}] 1

✓ Strong — the same Sharpness V sword in current component syntax (1.21.5–26.x): a flat ID→level map inside square brackets.

Namespace and spelling mistakes

Identifiers are case-sensitive and lowercase-only: Diamond_Sword, minecraft:dyamond_sword, and miecraft:diamond_sword all fail to parse, while diamond_sword (implicit minecraft namespace) and minecraft:diamond_sword both succeed. When a command references data-pack or modded content, the namespace is compulsory — /give @s gem_sword will never resolve to mymod:gem_sword.

Because component values are validated at parse time in 1.20.5+, an invalid value like [damage=-34] fails immediately rather than silently producing a broken item. Tab-completion is your friend: it suggests item IDs and component names (though not component values) as you type.

Stack limits and count errors

The trailing <count> argument accepts 1 to 2,147,483,647, but since 1.17 /give refuses to hand out more than 100 stacks' worth per execution — /give @s minecraft:diamond 6401 (just over 100×64) fails.

Overriding max_stack_size is capped at 99, and it is mutually exclusive with max_damage (an item cannot both stack and have durability). In 26.1+, a stack with conflicting data — a count above its max_stack_size, for instance — is treated as empty in many contexts, so sloppy component combinations can produce ghost items. Finally, remember the 256-character chat limit: long component stacks belong in a command block.

Bedrock vs Java differences

Bedrock Edition's /give is a different command with a different grammar — give <player: target> <itemName: Item> [amount: int] [data: int] [components: json] — and none of the component recipes on this page run there:

TopicJava EditionBedrock Edition
Item data in /giveFull data components: diamond_sword[enchantments={...}]No NBT/component item syntax; only 4 JSON item components (can_place_on, can_destroy, item_lock, keep_on_death)
Legacy data valuesGone since 1.13The data: int argument still exists (e.g. /give @a potion 1 5)
Enchanted itemsInline in one /giveGive the item, hold it, then /enchant
Custom names/lore via commandcustom_name, lore componentsNot possible via /give at all
Effect/enchantment IDsNamespaced (minecraft:speed)Unnamespaced (speed)

Bedrock did adopt namespaced string IDs, so minecraft:diamond_sword is portable between editions — only the data syntax differs. A converted Java component command still will not run on Bedrock, and Bedrock's JSON item components are not valid Java syntax.

Bottom line: only the bare namespaced ID crosses editions. Everything in square brackets on this page is Java-only; on Bedrock, give the plain item and use /enchant or an anvil for the rest.

Bottom line: nine out of ten /give failures are one of three things — old curly-brace NBT on a 1.20.5+ client, a casing or spelling slip in the ID, or a count above 100 stacks. Check those three against the parse error first, and consult the Bedrock table if you are not on Java Edition.

The same ID rules power every other content command. A quick reference — entity NBT still uses curly braces, because the 1.20.5 component migration applied to item stacks only:

/summon — entity IDs

Grammar: summon <entity> [<pos>] [<nbt>]. The entity argument is a namespaced entity-type ID from our entity ID list. Build complex spawns visually with the Summon Generator.

/summon minecraft:creeper ~ ~ ~ {powered:1b,NoAI:1b}
/summon minecraft:item ~ ~1 ~ {Item:{id:"minecraft:netherite_sword",count:1,components:{"minecraft:enchantments":{"minecraft:sharpness":5}}}}

An item stack embedded in entity NBT uses the saved item format: id, count, and a components map — the components form requires 1.20.5+, while plain entity NBT like the first example parses from 1.13 through 26.x.

/setblock — block IDs and block states

Grammar: setblock <pos> <block> [destroy|keep|replace|strict], where <block> is block_id[block_states]{nbt}. Block states in square brackets predate (and are unrelated to) item components; the strict placement mode was added in 1.21.5. Try the Setblock Command Generator.

/setblock ~ ~ ~ minecraft:chest[facing=east]
/setblock ~ ~2 ~ minecraft:quartz_slab[type=top]

/effect — status effect IDs

Grammar: effect give <targets> <effect> [<seconds>] [<amplifier>] [<hideParticles>]. The effect is a namespaced ID from our effect ID list. The infinite keyword (added 1.19.4) grants a permanent effect; the amplifier is zero-based — Speed II is amplifier 1 — and is capped at 255 since 1.20.5. Try the Effect Command Generator.

/effect give @s minecraft:resistance infinite 4 true
/effect give @p minecraft:speed 60 1

/enchant — enchantment IDs

Grammar: enchant <targets> <enchantment> [<level>] — enchants the item in the target's main hand, with anvil-style restrictions: the level cannot exceed the enchantment's normal maximum and incompatible combinations fail. Because /enchant enforces these limits while /give's enchantments component bypasses them (levels up to 255), the two commands are complementary: /enchant for legitimate upgrades, /give for custom "god items". IDs are on the enchantment ID list.

/enchant @s minecraft:sharpness 5
/enchant @a minecraft:infinity

Quick Reference Card

TaskCommand (Java 1.21.5+ / 26.x)
Basic give/give @s minecraft:diamond_sword 1
Sharpness X sword/give @r minecraft:diamond_sword[minecraft:enchantments={"minecraft:sharpness":10}] 1
Named, non-italic/give @s minecraft:stick[minecraft:custom_name={text:"Magic Wand",color:"light_purple",italic:false}]
With lore/give @s minecraft:diamond_sword[minecraft:lore=[{text:"A legend",italic:false}]] 1
Red leather tunic/give @s minecraft:leather_chestplate[minecraft:dyed_color=16711680] 1
Player head/give @s minecraft:player_head[minecraft:profile={name:"MHF_Sheep"}] 1
Strength II potion/give @s minecraft:potion[minecraft:potion_contents={potion:"minecraft:strong_strength"}] 1
Unbreakable pick/give @s minecraft:diamond_pickaxe[minecraft:unbreakable={}] 1
Mending book/give @s minecraft:enchanted_book[minecraft:stored_enchantments={"minecraft:mending":1}] 1
Stack of 64 totems/give @s minecraft:totem_of_undying[minecraft:max_stack_size=64] 64
Custom NBT data/give @s minecraft:stick[minecraft:custom_data={my_map:{key:1b}}]
Glint without enchant/give @s minecraft:stick[minecraft:enchantment_glint_override=true]

Bottom line: this card is the whole page compressed — every command here parses on Java 1.21.5 through 26.2. For 1.20.5–1.21.4 only the rows with text components need rewriting into JSON-string form.

Sources

Ready to Build Your Command?

Skip the bracket counting — or grab a raw ID and write the command yourself. New to /give entirely? Start with the basic Give Commands walkthrough.

🎮 Give Command Generator

  • ✓ Any of the 1,538 cataloged items — no ID memorization
  • ✓ Correct 1.20.5+ component syntax assembled for you
  • ✓ One-click copy of the finished command
Open the Give Command Generator →

Just need an ID? Browse the lists

  • ✓ Full item ID list with copy-ready namespaced IDs
  • ✓ Block IDs for /setblock and /fill commands
  • ✓ Legacy 1.12 numeric ID translations for old tutorials
Browse the Item ID List →

Minecraft Give Command FAQ

What is the current /give command syntax in Minecraft Java Edition?

On Java Edition 1.21.5 through 26.2 it is /give <targets> <item> [<count>], where <item> is a namespaced ID such as minecraft:diamond_sword optionally followed by data components in square brackets. Example: /give @s minecraft:diamond_sword 1. Cheats or operator permissions are required.

How do I give an enchanted item in Minecraft 1.20.5+?

Use the minecraft:enchantments component: /give @s minecraft:diamond_sword[minecraft:enchantments={"minecraft:sharpness":5}] 1. On 1.21.5 and later the map is flat (enchantment ID to level); on 1.20.5–1.21.4 the levels are wrapped in a levels object. Levels up to 255 are accepted, bypassing the normal caps that /enchant enforces.

Why does my /give command with curly braces fail?

Curly-brace NBT on items was removed in Java Edition 1.20.5 and replaced by square-bracket data components. /give @p diamond_sword{Enchantments:[{id:"minecraft:sharpness",lvl:5s}]} only parses on 1.13–1.20.4; on current versions use [minecraft:enchantments={"minecraft:sharpness":5}] instead.

What happened to numeric item IDs like 276?

Java Edition removed numeric IDs in 1.13 ("The Flattening"). Items and blocks are now identified only by namespaced strings such as minecraft:diamond_sword. Old commands like /give @p 276 1 0 cannot work on any modern version.

Do I need the minecraft: prefix in item IDs?

For vanilla content the prefix is optional — the game resolves diamond_sword to minecraft:diamond_sword automatically. Writing the full namespaced form is recommended, and the namespace is mandatory when referencing modded or data-pack content.

Why does my renamed item command fail on 1.21.5+?

Java Edition 1.21.5 changed text components from JSON strings to inline SNBT. custom_name='{"text":"Excalibur"}' (valid on 1.20.5–1.21.4) must be rewritten as custom_name={text:"Excalibur"} on 1.21.5 and later.

Is there a limit to how many items /give can give at once?

Yes. The count argument accepts up to 2,147,483,647, but since 1.17 /give refuses to hand out more than 100 stacks' worth per execution — /give @s minecraft:diamond 6401 fails. Split larger amounts across multiple commands or command blocks.

Do these /give commands work on Bedrock Edition?

No. Bedrock has a different /give grammar with no item component syntax — enchantments, custom names, and lore cannot be set through /give at all. Namespaced IDs like minecraft:diamond_sword are portable between editions, but Java's square-bracket components and Bedrock's JSON item components are not interchangeable.

Does the /give command work without cheats enabled?

No. /give requires cheats: toggle Allow Cheats when creating a singleplayer world, open to LAN with cheats for an existing one, hold operator status on a server, or run the command from a command block. There is no way to use /give in a world where cheats are fully disabled.

How do I find the exact item ID for a give command?

In Java Edition, press F3+H to enable Advanced Tooltips and hover the item, or use tab-completion while typing the command. On this site, every entry on the item ID list and block IDs pages shows a copy-ready namespaced ID, and the give command generator builds the full command for you.