Skip to main content

/weather

Sets the weather to clear skies, rain, or thunderstorm for an optional duration.

Permission Level
Game Master
Version Added
1.4.2

Overview

Sets the weather to clear skies, rain, or thunderstorm for an optional duration. In vanilla Minecraft Java Edition it is one of the time & weather commands, first added in 1.4.2.

It is invoked as /weather <clear|rain|thunder> [<duration>] and accepts one required argument (<type>) and one optional argument ([duration]).

To keep the weather you set, run /gamerule advance_weather false afterwards (the rule was called doWeatherCycle before Java 1.21.11). Thunderstorms make the sky dark enough for monsters to spawn during the day. Since Java 1.20.5 the command also works when run in the Nether or the End.

Leave the duration out and the game picks one at random, and the ranges are far apart: a clear spell can last anywhere from 10 to 150 minutes, a thunderstorm only 3 to 13.

Syntax & Arguments

/weather <clear|rain|thunder> [<duration>]

The full syntax is /weather <clear|rain|thunder> [<duration>]. Angle brackets < > mark required arguments and square brackets [ ] mark optional ones; a vertical bar | between words means you pick exactly one of those literals. You must always supply <type>. The argument [duration] may be omitted, in which case the documented default applies.

type
Required, of type a literal. The weather type: clear, rain, or thunder.
duration
Optional, of type a time. How long the weather lasts. A bare number is read as ticks; add s for seconds or d for in-game days (1d = 24000 ticks). If omitted, the game picks a random length: 12000 to 180000 ticks for clear, 12000 to 24000 for rain and 3600 to 15600 for thunder.

Parameters

NameTypeRequiredDescription
typeliteralRequiredThe weather type: clear, rain, or thunder.
durationtimeOptionalHow long the weather lasts. A bare number is read as ticks; add s for seconds or d for in-game days (1d = 24000 ticks). If omitted, the game picks a random length: 12000 to 180000 ticks for clear, 12000 to 24000 for rain and 3600 to 15600 for thunder.

Examples

The 3 examples below are ready to copy and adapt. For instance, /weather clear sets the weather to clear for a random duration. Each example varies the arguments to show a different real use of /weather; read the note under every snippet to see exactly what changes.

/weather clear

Sets the weather to clear for a random duration.

/weather thunder 300s

Starts a thunderstorm that lasts 300 seconds, which is five minutes. Without the s it would last 300 ticks, only 15 seconds.

/weather clear 1d

Keeps the sky clear for one full in-game day (24000 ticks, about 20 real minutes).

Permission Level & Requirements

/weather sits at permission Level 2 - Game Master / Cheats, which means it needs permission level 2, the level cheats grant to single-player worlds and that operators hold by default.

In a single-player world you must have "Allow Cheats" turned on (or open the world to LAN with cheats) before it will run; on a multiplayer server the player needs to be an operator at the matching level.

This reference describes the Java Edition 1.21 form of the command; Bedrock Edition may use slightly different argument formats.

Common Mistakes

Notes

To keep the weather you set, run /gamerule advance_weather false afterwards (the rule was called doWeatherCycle before Java 1.21.11). Thunderstorms make the sky dark enough for monsters to spawn during the day. Since Java 1.20.5 the command also works when run in the Nether or the End.

Related Commands

If /weather is part of your toolkit, the commands below are the ones you will most often reach for alongside it: /time and /gamerule. They cover closely related tasks, so the links above jump straight to each one.

Frequently Asked Questions about /weather

What does the /weather command do in Minecraft?

Sets the weather to clear skies, rain, or thunderstorm for an optional duration. It belongs to the time & weather command group and was first added in Java Edition 1.4.2.

What is the correct syntax for /weather?

/weather <clear|rain|thunder> [<duration>]. The required argument is type, and the optional one is duration.

What permission level does /weather need?

It requires permission Level 2 - Game Master / Cheats. On a server the player must be an operator at that level, or have cheats enabled in single-player.

What is a common mistake when using /weather?

Expecting thunder to include lightning strikes constantly, lightning is random during thunderstorms.

Can you give an example of /weather in use?

Yes. /weather thunder 300s: starts a thunderstorm that lasts 300 seconds, which is five minutes. Without the s it would last 300 ticks, only 15 seconds.

Need a Minecraft server?

Try these commands on Astroworld or host your own server.

Try Astroworld Hosting