News
Game
Guides
Downloads
Versions
/schedule
COMMANDS COMMAND BLOCKS & MAPS CHEATS · LEVEL 2 Added in 1.14 or earlier

/schedule command in Minecraft

/schedule runs a data pack function or function tag after a delay given in ticks, seconds or in-game days. It is the clean way to build timers, countdowns and loops that should run less often than every tick. /schedule clear cancels what is still waiting.

Syntax

/schedule clear <function>
/schedule function <function> <time> [append|replace]
ArgumentExpectsWhat it does
functionResource IDFunction or function tag to run, for example mypack:countdown or #mypack:timers. With clear, the ID to cancel.
timeDuration (ticks, or 10s, 2d)at least 0Delay before the run: 20 or 20t in ticks, 5s in seconds, 1d in in-game days. At least one tick.
All 4 forms
  • /schedule clear <function>
  • /schedule function <function> <time>
  • /schedule function <function> <time> append
  • /schedule function <function> <time> replace

Examples

Run a function in 5 seconds

/schedule function mypack:countdown 5s

Runs mypack:countdown once, 5 seconds (100 ticks) from now.

Java 26.3

Queue an extra run

/schedule function mypack:loop 1t append

Adds one more run of mypack:loop on the next tick, without cancelling the runs already planned.

Java 26.3

Wait one in-game day

/schedule function mypack:night 1d replace

Runs mypack:night after 24,000 ticks and replaces any pending run of the same function.

Java 26.3

Schedule a function tag

/schedule function #mypack:timers 20t

Runs every function of the mypack:timers tag after 20 ticks, one second.

Java 26.3

Cancel a countdown

/schedule clear mypack:countdown

Removes every pending run of mypack:countdown.

Java 26.3
Build your command

Fill in the fields, then copy the command.

Command generator

Delays and units

The delay accepts a unit: t for ticks (the default), s for seconds (20 ticks) and d for in-game days (24,000 ticks). A delay of 0t fails with "Can't schedule for current tick": the minimum is one tick. By default replace applies, so scheduling the same function again moves its single pending run to the new time. append keeps the earlier runs and adds one more.

What changes in the function

A scheduled function does not keep the context of the command that planned it. It runs from the server, not from the player or the command block, so @s selects nobody. Select players with @a or a tag, or use /execute inside the function. Macro functions cannot be scheduled: the game answers "Can't schedule a macro". To run a function right now, use /function instead.

Loops and cancelling

A function whose last line is schedule function mypack:loop 1s calls itself every second, which is much lighter than a tick function. Stop the loop with /schedule clear mypack:loop. If nothing is waiting, the game reports "No schedules with ID ...". Combine it with /scoreboard to count down a timer second by second.

✓ Checked in Java Edition 26.3 · updated 2 November 2026

/schedule: FAQ

Why does @s not work in a scheduled function?

The function runs from the server, not from the player who scheduled it. Select players with @a or a tag, or use execute as inside the function.

What is the difference between replace and append?

replace, the default, keeps a single pending run and moves it to the new time. append adds another run and leaves the earlier ones in place.

How do I use /schedule?

Type it in the chat with cheats on: /schedule clear <function>.

Who can use /schedule?

Cheats on, or operator level 2.

Related commands