Skip to content
MC Command Generator

Infinite effect command: permanent night vision with no particles

GuideJava 1.19.2 → 26.3 · Bedrock5 min read4 commands

/effect give @a minecraft:night_vision infinite 0 true gives a permanent effect with no particles on Java 1.19.4+. Older versions top out at 1,000,000 seconds.

Write infinite where the seconds go: /effect give @a minecraft:night_vision infinite 0 true. That works on Java 1.19.4 and later. The 0 is the level (0 = level I) and the final true hides the particles.

#1Night Vision forever, no particles (Java 1.19.4+)Epic

infinite in place of the seconds, 0 for level I, true to hide the particles and the HUD icon.

effect give @a minecraft:night_vision infinite 0 true
Open in /effect Java 26.3

What the game stores

We gave a pig Night Vision on a Java 26.3 server, first plain, then with 0 true, and read its data after each. An infinite effect is saved with a duration of -1.

Server log · Java 26.3
  1. effect give @e[tag=p1] minecraft:night_vision infinite
    Applied effect Night Vision to Pig
  2. data get entity @e[tag=p1,limit=1] active_effects
    Pig has the following entity data: [{duration: -1, show_icon: 1b, id: "minecraft:night_vision"}]
  3. effect give @e[tag=p1] minecraft:night_vision infinite 0 true
    Applied effect Night Vision to Pig
  4. data get entity @e[tag=p1,limit=1] active_effects
    Pig has the following entity data: [{duration: -1, show_icon: 0b, id: "minecraft:night_vision", show_particles: 0b}]

Two things in that second read. You can run the hidden version straight over the visible one; there is no need to clear first. And true turns off more than the swirls: show_icon went to 0 as well, so the effect no longer shows in the corner of the screen.

How the particles come back by accident

Here is the trap. If anything later gives the same effect without true, a beacon-style command block for example, the hidden infinite effect is not replaced, but its particles are switched back on. We gave the pig a plain 60-second Night Vision on top of the hidden infinite one:

Server log · Java 26.3
  1. effect give @e[tag=p1] minecraft:night_vision infinite 0 true
    Applied effect Night Vision to Pig
  2. effect give @e[tag=p1] minecraft:night_vision 60
    Applied effect Night Vision to Pig
  3. data get entity @e[tag=p1,limit=1] active_effects
    Pig has the following entity data: [{duration: -1, show_icon: 1b, id: "minecraft:night_vision"}]

Still infinite (duration -1), but show_icon is 1 again and the show_particles: 0b entry is gone. Running the hidden command once more put it back. A stronger level behaves differently: a 60-second Night Vision II took over for its minute and kept the infinite one underneath as hidden_effect.

And the amplifier is not optional if you want to hide particles. effect give @e[tag=p1] minecraft:speed 60 true answered Expected integer; 60 0 true worked.

The limits: seconds and levels

Server log · Java 26.3
  1. effect give @e[tag=p1] minecraft:speed 1000000
    Applied effect Speed to Pig
  2. effect give @e[tag=p1] minecraft:haste 1000001
    Integer must not be more than 1000000: found 1000001
  3. effect give @e[tag=p1] minecraft:strength 30 255
    Applied effect Strength to Pig
  4. effect give @e[tag=p1] minecraft:resistance 30 256
    Integer must not be more than 255: found 256
  5. effect give @e[tag=p1] minecraft:slowness 0
    Integer must not be less than 1: found 0

One million seconds is 277 hours, a little over eleven and a half days. That number matters on old versions, where it is the closest thing to forever.

What if my version says “infinite” is wrong?

infinite was added in Java 1.19.4. A 1.19.2 server does not know the word and asks for a number; the one-million-second version goes through.

Server log · Java 1.19.2
  1. effect give @e[tag=p1] minecraft:night_vision infinite 0 true
    Expected integer
  2. effect give @e[tag=p1] minecraft:speed 1000000
    Applied effect Speed to Pig
The same form (Night Vision, forever, hidden) written by the /effect generator for each version.
VersionCommand
Java 1.19.4 – 26.3effect give @a minecraft:night_vision infinite 0 true
Java 1.13 – 1.19.2effect give @a minecraft:night_vision 1000000 0 true“infinite” needs Java 1.19.4 or later — Night Vision got the longest time instead (1,000,000 seconds, about 11½ days).
Java 1.12effect @a 16 1000000 0 true“infinite” needs Java 1.19.4 or later — Night Vision got the longest time instead (1,000,000 seconds, about 11½ days).
Bedrockeffect @a night_vision infinite 0 true
#2The longest timed effect (Java 1.13 – 1.19.2)Rare

Before 1.19.4 there is no infinite. 1,000,000 seconds is the most the command takes: about eleven and a half days.

effect give @a minecraft:night_vision 1000000 0 true
Open in /effect Java 1.19 – 1.19.2
#3The same on BedrockRare

Bedrock has no give keyword; the rest is the same order.

effect @a night_vision infinite 0 true
Open in /effect Bedrock 26.50+

We could not run Bedrock on our test server. The Bedrock line is what the /effect generator writes; its notes on infinite for Bedrock (from 1.21.40) come from minecraft.wiki’s /effect history.

Turning it off

/effect clear with the effect name removes just that one; without a name it removes everything. On 26.3 the answers were “Removed effect Night Vision from Pig” and “Removed every effect from Pig”.

#4Take it off againRare

Removes Night Vision from everyone and leaves their other effects alone.

effect clear @a minecraft:night_vision
Open in /effect Java 26.3

Want a whole set of effects in one command? That is coming with effect tags in 26.4: /effect with tags, tested on the snapshot.

FAQ

What is the command for infinite night vision?

/effect give @a minecraft:night_vision infinite 0 true on Java 1.19.4 and later, including 26.3. The last word, true, hides the particles.

How do I give an effect without particles?

Add the amplifier and then true: /effect give @p minecraft:speed 60 0 true. You cannot skip the amplifier, so write 0 for level I. On our 26.3 server the saved effect then had show_particles: 0b and show_icon: 0b.

What is the longest effect duration?

1,000,000 seconds. Our server refused 1000001 with: Integer must not be more than 1000000. The highest amplifier is 255 (256 is refused).

Why did my particles come back?

A later /effect for the same effect without true switches them back on. In our test a 60-second Night Vision given on top of a hidden infinite one left the effect infinite but visible again.