/weather clearThe /weather command changes the weather in the current world. Thunder weather also enables mob spawning like charged creepers from lightning. Use /gamerule doWeatherCycle false to freeze the weather.
The /weather command sets the world weather to clear, rain, or thunder. Pick a state, add an optional duration, and this generator builds the exact syntax. Weather in Minecraft does more than change the sky: it affects mob spawning, light levels, and block behavior.
Minecraft has three weather states: clear, rain, and thunder. When the doWeatherCycle gamerule is enabled (it is by default), the game randomly cycles between these states. Rain typically lasts between 12,000 and 24,000 ticks, with clear periods varying similarly.
The /weather command overrides the natural cycle and forces a specific state. You can optionally specify how long it lasts. Combined with /gamerule doWeatherCycle false, you get full control over the sky.
| Command | Effect |
|---|---|
| /weather clear | Forces clear skies with no precipitation |
| /weather rain | Starts rain (falls as snow in cold biomes) |
| /weather thunder | Starts a thunderstorm with lightning and daytime mob spawns |
| /weather rain 6000 | Forces rain for exactly 6,000 seconds |
| /weather clear 0 | Clears the weather for the shortest possible duration |
Duration is in seconds in Java Edition. If you leave it off, the game picks a random length. Weather only applies to the Overworld; the Nether and the End always show clear skies regardless of the weather state.
Clear weather is the default state. Full sky light reaches exposed blocks, undead mobs burn during daytime, and no special effects apply. It is best for building and exploration.
Rain reduces the effective sky light level and puts out fires on exposed blocks. Wolves shake themselves dry, cauldrons slowly fill with water, and bees return to hives. In snowy biomes, rain falls as snow and can add snow layers up to the snowAccumulationHeight gamerule limit. Farmland stays hydrated in rain without a nearby water source.
Thunderstorms are the most impactful state. Light levels in exposed areas drop low enough that hostile mobs spawn during daytime. Lightning strikes occur randomly and can set blocks on fire, turn pigs into zombified piglins, create charged creepers, convert villagers into witches, and activate lightning rods within a 128-block area. A Channeling trident can target specific mobs with lightning during a thunderstorm.
Run /weather clear in the chat. For a permanent fix, also disable the weather cycle with /gamerule doWeatherCycle false. Without this, the game will eventually cycle back to rain on its own.
Rain is mostly cosmetic. It slightly dims the sky and puts out fires. Thunderstorms are mechanically different: they drop the effective light level low enough for hostile mobs to spawn during the day, and they produce lightning strikes that can create charged creepers, zombified piglins, and witches.
With default settings, rain lasts a random duration between roughly 12,000 and 24,000 ticks (10-20 minutes). You can override this by specifying a duration: /weather rain 6000 forces rain for exactly 6,000 seconds (100 minutes).
Natural lightning targets random positions, not players specifically. However, a player can be hit by chance if standing at the strike point. Lightning rods attract strikes within a 128-block area, redirecting them safely away from builds and mobs.
Browse more Minecraft tools: