Close Command
by Anvalance
Close Command lets a player schedule the game to exit on its own once a chosen span of time has passed, which is handy for ending a session at a set moment.
What it does
The mod adds a close command to Minecraft. Once a timer runs, the client closes the game when the time is up. Time can be entered in several forms such as 5 minutes, 90s, 1:30:00 or 5h, and units from milliseconds to years, with decimals, are accepted as well. A player who falls asleep during a long AFK stretch or leaves the game running overnight can cap the session this way.
Two modes are available. The default mode closes the game instantly, while the other first saves the world and then closes. Starting a new timer replaces any timer already running rather than stacking on top of it. Tab-completion suggests units and example inputs as the command is typed.
Close Command runs on the client alone, so the server does not need it and nothing has to be installed there. The mod requires Fabric API and is published for Fabric, with files for 1.21.11, released under the MIT License. It is not open source.
Key features
Several time formats
Durations can be written in multiple formats, including minutes, seconds, hour and minute notation, and larger units such as years.
Timer replacement
Each new close command replaces the timer already running, so timers never stack up during a session.
Instant or save-first mode
The default mode closes the game at once, and the alternative saves the world before shutting down.
Tab-completion suggestions
Typing the command shows suggested units and example inputs, so the correct format can be found while typing.
Compatibility
Latest build for each game version and loader.
Only full game releases are shown. This mod publishes no snapshot builds.
Use cases
Capping a play session
A player who wants to stop after a fixed length of time sets the timer and can walk away without leaving the game open.
Preventing overnight play
Setting a timer before bed closes the game automatically if the player falls asleep during a long AFK period.
Who it’s for: Players who want the game to close itself at a set time, especially during long sessions, AFK periods or unattended stretches. Only the client needs the mod.
Questions
Does Close Command need to be installed on the server?
What does Close Command require?
Does a new close command add to an existing timer?
In the catalog
Close Command is one of 7,216 Magic mods on ModsFinder, and one of 3,630 Magic mods for Fabric. 19,862 mods support Minecraft 1.21.11.
Similar mods
What the author says
A lightweight client-side mod that adds /close — tell Minecraft to shut itself down after a set amount of time. Great for falling asleep mid-AFK, capping a play session, or just walking away without leaving the game running all night. Client-side only — no server install needed. Requires Fabric API.
Official listing
- Modrinth page
- modrinth.com/mod/close-command
- Owner
- Anvalance
- Published
- 2026-05-29
- Updated on Modrinth
- 2026-05-29
- Facts verified
- 2026-10-15
