What the /effect command does
The /effect command hands status effects to players or mobs, or strips effects that are already active. These are the same buffs and debuffs you get from potions, beacons, and certain foods: speed, regeneration, poison, night vision, and dozens more. The command gives them out instantly, at any level you pick, for as long as you want.
You need cheats turned on in a single-player world, or operator permission on a server, before it will run. If you type /effect and nothing happens, that is almost always why.
It works in both Java and Bedrock editions, but the way you write it differs between them. This guide covers both.
Syntax in Java Edition
Since version 1.13, Java splits the command into two parts: one to add an effect, one to remove it.
To add an effect:
/effect give <targets> <effect> [seconds] [amplifier] [hideParticles]
To remove one:
/effect clear [targets] [effect]
Here is what each part means:
targets: who gets the effect. Use a player name or a target selector such as@s(yourself),@a(all players),@p(nearest player),@r(random player), or@e(all entities).effect: the effect ID, likespeed,jump_boost, ornight_vision. You can write the plain name or the fullminecraft:speedform.seconds: how long it lasts. Leave it out and you get 30 seconds. The range runs from 1 up to 1,000,000. From1.19.4on, you can typeinfinitefor an effect that never wears off.amplifier: the strength of the effect, counted from zero. A value of 0 is level I, 1 is level II, and so on up to 255.hideParticles:trueorfalse. Set it totrueand the swirling colored particles disappear. The default isfalse.
When you clear, leaving the effect blank removes everything the target has. Naming one effect removes only that one.
Syntax in Bedrock Edition
Bedrock does not use the give and clear subcommands. The structure is flatter:
/effect <target> <effect> [seconds] [amplifier] [hideParticles]
To wipe every effect off a target:
/effect <target> clear
To remove a single effect in Bedrock, set its duration to zero. For example, /effect @s speed 0 ends an active Speed effect without touching anything else. The same selectors work as in Java, and the default duration is again 30 seconds if you leave it out.
Choosing targets
Target selectors decide who the command hits. You can always type an exact player name instead, but selectors are faster and work in command blocks.
| Selector | Who it targets |
|---|---|
@s |
Whoever or whatever runs the command |
@p |
The nearest player |
@a |
Every player in the world |
@r |
A random player |
@e |
All entities, including mobs |
Because @e reaches mobs, you can buff a pet wolf or weaken a raid the same way you would a player.
Effect names you can use
You reference effects by name, not by the old number IDs that Java retired in 1.13. The helpful ones include speed, haste, strength, jump_boost, regeneration, resistance, fire_resistance, water_breathing, night_vision, invisibility, slow_falling, health_boost, and absorption.
The harmful ones include slowness, mining_fatigue, poison, wither, weakness, hunger, nausea, blindness, darkness, and levitation. There are also instant effects, instant_health and instant_damage, which fire once and ignore any duration you set.
Duration, levels, and particles
The number that trips people up most is the amplifier. The game counts from zero, so the level you see in your inventory is always the amplifier plus one. If you want Strength II, you type amplifier 1. Typing 2 gives you Strength III. To reach the highest tier the bar will display, you usually want amplifier 4 or higher.
Duration is measured in seconds, not ticks, which makes it easy to reason about. A value of 60 is one minute. Instant effects are the exception, since they apply the moment the command runs and the seconds value is ignored.
Hiding particles is handy for builds and adventure maps where you want the effect without the visual noise. Set hideParticles to true and the player still gets the buff, just without the colored swirl around them.
Useful examples
A few commands you will reach for often:
/effect give @s night_vision infinite 0 truegives you permanent night vision with no particles in Java1.19.4and later./effect give @a speed 120 2gives every player Speed III for two minutes./effect give @s water_breathing 600 0lets you stay underwater for ten minutes./effect clear @sremoves every effect you currently have in Java./effect @s strength 60 1is the Bedrock way to give yourself Strength II for one minute.
How /effect differs from potions
Drinking a potion and running the command land you in the same place, but the command gives you more control. Potions cap out at the levels the game brews, usually I or II, and they cost ingredients and brewing time. The command lets you set any level up to 255 and any duration you like, with no glass bottles involved.
The command also reaches across distance. A potion only affects whoever drinks it, while /effect give @a hits every player at once, no matter where they stand. That makes it the tool of choice for server events, minigames, and testing how a build feels with a buff active.
Using /effect in command blocks and maps
The command shines inside command blocks on adventure maps. A repeating command block running /effect give @a saturation 1 255 true keeps every player fed without showing a single particle, so hunger never interrupts the experience. Map makers lean on the hideParticles flag constantly for this reason, since the buffs stay invisible while the effect still works.
Pair it with target selector arguments for finer control. For example, /effect give @a[distance=..10] regeneration 5 1 only heals players within ten blocks of the command block, which lets you build healing zones, safe rooms, or trap rooms that drain health with poison the moment someone steps inside.
Common mistakes
The amplifier mix-up is the big one. Asking for “level 2” by typing 2 actually gives level III, because the count starts at zero.
The other frequent slip is using the give subcommand on Bedrock, or skipping it on Java. Java needs /effect give; Bedrock does not have it. If the command refuses to run, check which edition you are on.
Old guides sometimes show numeric effect IDs like 1 for Speed. Those stopped working in Java 1.13. Use the names instead. And remember that infinite only works in Java 1.19.4 and up; on older versions or on Bedrock, use a large number of seconds for a near-permanent effect.
Java vs Bedrock differences
The core idea is identical, but three things change between editions. Java uses give and clear as subcommands, while Bedrock puts the effect right after the target and clears a single effect by setting its seconds to 0. Java accepts infinite as a duration; Bedrock does not, so you supply a big number there. Beyond that, the selectors, level counting, and particle toggle behave the same way.
Frequently asked questions
How do I give myself permanent night vision?
In Java 1.19.4 or later, run /effect give @s night_vision infinite 0 true. On older versions or on Bedrock, use a long duration like /effect give @s night_vision 999999 0 true in Java, or /effect @s night_vision 999999 0 true in Bedrock.
How do I remove an effect?
In Java, use /effect clear @s to remove all of them, or name one to remove just that effect. In Bedrock, use /effect @s clear for everything, or set a single effect to zero seconds.
What does the amplifier number mean?
It is the effect level minus one. Amplifier 0 is level I, amplifier 1 is level II, and so on. The level shown in your inventory is always one higher than the number you type.
Can I give effects to mobs?
Yes. Use @e to reach all entities, or narrow it with selector arguments so you only hit the mobs you want. This works on pets, farm animals, and hostile mobs alike.
Why is the /effect command not working?
Cheats have to be on, or you need operator permission on a server. Check that too, along with whether you are using give correctly for your edition and spelling the effect name right.
What is the longest duration I can set?
In Java the seconds value goes up to 1,000,000, or you can use infinite from 1.19.4. In Bedrock you supply a large number of seconds rather than a keyword.
Can you have several effects at once?
Yes. Different effects stack freely, so you can run speed, jump boost, and regeneration together. Applying the same effect again replaces the old one rather than adding to it, and the higher level or longer timer wins.
Does /effect work in command blocks?
It does, and command blocks are where it gets the most use. Set the block to repeating with hideParticles on, and you can maintain an effect across a whole map without players ever seeing it.
Keep a couple of these commands in your back pocket and the /effect command turns into a quick fix for almost any situation: a night dive, a tough fight, or a creative build where you just want to float in place with levitation and study your work from above.