Pixel art illustration of a straight minecart rail with wooden ties and two iron rails
Minecraft Java Item ID

Rail ID

Rail is a transportation block used for minecart tracks. It is crafted from iron ingots and sticks, and can be placed on solid blocks.

✓ Verified for Java Edition 26.2
Namespaced item ID minecraft:rail

Rail Item Facts

Maximum stack64
Available inSurvival and Creative
Historical numerical ID66

Historical numerical ID: Reviewed for Java Edition 1.12.2 and earlier.

Give Command for Rail

Copy the current Java Edition command, or open the generator to change the player and quantity.

/give @p minecraft:rail 1

Customize this command → View crafting recipe →

Historical command for Java 1.12.2 and earlier

Modern namespaced IDs are recommended. This numerical form is only for old Java releases.

/give @p 66 1

Give command syntax by version

Java 1.13+
/give @p minecraft:rail 1
Namespaced ID (current format)
Java 1.8–1.12.2
/give @p 66 1 0
Numerical ID + data value
Bedrock Edition
/give @p minecraft:rail 1
Same namespaced ID (namespace optional)

Rows appear only when the underlying value is verified: the Java 1.8–1.12.2 row requires a reviewed historical numerical ID, and the Bedrock row appears only when this exact namespaced ID exists in the Bedrock registry.

How to Get Rail

Crafting Recipe

Iron IngotIron Ingot
Iron IngotStickIron Ingot
Iron IngotIron Ingot

Crafting table recipe — makes 16 × Rail.

More Ways to Get It

Craft Rails from six iron ingots and one stick. Rails create a path for minecarts and can be combined with powered rails for longer transport systems.

  1. Collect six iron ingots and one stick.
  2. Craft Rails at a Crafting Table.
  3. Lay rails on solid blocks and add minecarts or powered sections.

Prefer commands? Jump back to the give command matrix above to get Rail instantly.

Rail Command Examples

  • Give 1 to nearest player: /give @p minecraft:rail 1
  • Give 1 to yourself: /give @s minecraft:rail 1
  • Give to a specific player: /give PlayerName minecraft:rail 1
  • Clear from inventory: /clear @p minecraft:rail

What Is Rail Used For?

Minecart

Use rails as the track for a standard minecart.

Powered Rail

Add powered segments to accelerate or control carts.

Iron Ingot

Iron ingots are the primary rail ingredient.

Rail FAQ

What is the item ID for Rail?

The item ID for Rail is minecraft:rail. Java Edition commands such as /give, /clear, and /setblock use this namespaced ID.

What is the numerical ID for Rail?

Rail has the historical numerical ID 66, used in Java Edition 1.12.2 and earlier. Current versions use minecraft:rail instead.

How do I give myself Rail in Minecraft?

Open the chat window and run /give @p minecraft:rail 1 to give the nearest player one Rail. Replace @p with a player name to target someone else.

How many Rail can stack in one slot?

Rail stacks up to 64 per inventory slot.

How do you craft Rail?

Rail is crafted on a crafting table with 6 iron ingots and 1 stick, which yields 16 Rail.

Sources and Data Review

Item facts were reviewed for Java Edition 26.2 on .

Related Transportation

Item ID: minecraft:minecart
Item ID: minecraft:powered_rail
Item ID: minecraft:chest_minecart
Item ID: minecraft:iron_ingot
Item ID: minecraft:redstone
Item ID: minecraft:saddle
Item ID: minecraft:elytra
Item ID: minecraft:detector_rail