News
Game
Guides
Downloads
Versions
/attribute
COMMANDS PLAYERS & MOVEMENT CHEATS · LEVEL 2 Added in 1.16

/attribute command in Minecraft

/attribute reads or changes the attributes of a player or mob: maximum health, speed, size, gravity, reach and many more. You can edit the base value, or add named modifiers that stack on top of it and can be removed later.

Syntax

/attribute <target> <attribute> (base|get|modifier)
ArgumentExpectsWhat it does
targetEntity selectoroneOne entity to read or change: @s, a player name or @e[type=minecraft:zombie,limit=1,sort=nearest].
attributeID · attributeAttribute ID, for example minecraft:max_health, minecraft:scale or minecraft:movement_speed.
scaleoptionalNumberOptional factor applied to the returned value, handy when storing it as a whole number.
valueNumberNew base value, or the amount of the modifier. Decimals are allowed, such as 0.5.
idResource IDYour own identifier for the modifier, namespace and name, for example blockaria:boost.
All 12 forms
  • /attribute <target> <attribute> base get
  • /attribute <target> <attribute> base get <scale>
  • /attribute <target> <attribute> base reset
  • /attribute <target> <attribute> base set <value>
  • /attribute <target> <attribute> get
  • /attribute <target> <attribute> get <scale>
  • /attribute <target> <attribute> modifier add <id> <value> add_multiplied_base
  • /attribute <target> <attribute> modifier add <id> <value> add_multiplied_total
  • /attribute <target> <attribute> modifier add <id> <value> add_value
  • /attribute <target> <attribute> modifier remove <id>
  • /attribute <target> <attribute> modifier value get <id>
  • /attribute <target> <attribute> modifier value get <id> <scale>

Examples

Double your size

/attribute @s minecraft:scale base set 2

Sets your scale to 2, making you twice as big.

Java 26.3

Twenty hearts of health

/attribute @s minecraft:max_health base set 40

Raises your maximum health to 40 points, which is 20 hearts.

Java 26.3

A removable speed boost

/attribute @s minecraft:movement_speed modifier add blockaria:boost 0.5 add_multiplied_base

Adds half of your base speed under the ID blockaria:boost.

Java 26.3

Remove the speed boost

/attribute @s minecraft:movement_speed modifier remove blockaria:boost

Deletes the modifier added above and brings your speed back.

Java 26.3

Check your block reach

/attribute @s minecraft:block_interaction_range get

Prints how far you can currently reach blocks, modifiers included.

Java 26.3
Build your command

Fill in the fields, then copy the command.

Command generator

Base value or modifier

base set changes the entity's own value and base reset restores the default. modifier add stacks a change on top, under an ID you choose, such as blockaria:boost. Three operations exist: add_value adds a flat amount, add_multiplied_base adds a share of the base value, and add_multiplied_total multiplies the total. get returns the final value with every modifier, including those from effects such as Speed given by /effect; base get returns the base only. The optional scale multiplies the returned number, useful with /execute store.

Useful attributes

  • minecraft:max_health: 20 for a player, which is ten hearts.
  • minecraft:scale: makes an entity bigger or smaller.
  • minecraft:gravity, minecraft:jump_strength and minecraft:step_height: movement.
  • minecraft:block_interaction_range: how far a player reaches blocks.

Common errors

"Entity Pig has no attribute minecraft:attack_damage" means the mob does not use that attribute, as here with a Pig. "Modifier blockaria:boost is already present on attribute minecraft:movement_speed for entity Steve" asks for a new ID or a removal first. To spawn a mob with custom values, set them right after /summon.

✓ Checked in Java Edition 26.3 · updated 2 November 2026

/attribute: FAQ

Why is my health bar not full after raising max_health?

The maximum grows, but the current health stays the same. Regenerate, or give an Instant Health effect, to fill the new hearts.

How do I undo an attribute change?

Use base reset for a base value, or modifier remove with the same ID for a modifier.

How do I use /attribute?

Type it in the chat with cheats on: /attribute <target> <attribute> (base|get|modifier).

Who can use /attribute?

Cheats on, or operator level 2.

Since when does /attribute exist?

It is in the official command tree since Java Edition 1.16.

Related commands