mcrcon
Command-line RCON client for Minecraft servers
mcrcon is a tiny, portable RCON client for remotely administering Minecraft and other RCON-capable game servers from the command line. It is commonly used in scripts to automate self-hosted game server management.
Key features
- Portable RCON client
- Command-line automation
- Works with many games
- Tiny binary
Pros & cons
Strengths
- Extremely lightweight
- Scriptable
Trade-offs
- No GUI
- Single-purpose tool
mcrcon replaces
Last reviewed Sep 13, 2026 · 811 words
The repository behind this entry is Tiiffi's mcrcon, a single C binary under the zlib licence that sends RCON commands to a game server and prints the reply. It is not a controller, not a Discord bot and not a note; it is the tool you call from cron to run save-all before a backup, and the reason it has 1,080 stars is that nearly every Minecraft backup script written since 2012 shells out to it. It fits in 16 MB of RAM, compiles in two seconds, and I keep it on every box that runs a game server.
What mcrcon is and is not
RCON is the remote console protocol Valve defined for Source engine servers, and Minecraft, Factorio, Rust, ARK, Palworld and dozens of others implement the same wire format. mcrcon speaks it from the command line:
mcrcon -H 127.0.0.1 -P 25575 -p 's3cret' "say Backup in 60 seconds" "save-all" "list"
Each quoted argument is one command, run in order, with the server's reply printed. Add -t for an interactive terminal session where you type commands and see responses live, and -s for silent mode in scripts. MCRCON_HOST, MCRCON_PORT and MCRCON_PASS as environment variables keep the password out of your shell history and ps output.
There is no GUI, no state and no daemon. It does one thing on demand and exits. That single-purpose design is exactly why it belongs in scripts and why it is the wrong tool if you want a web page with a Start button.
Enable RCON on the server first
Minecraft ships with RCON off. In server.properties:
enable-rcon=true
rcon.port=25575
rcon.password=s3cret
broadcast-rcon-to-ops=true
Restart the server and confirm with mcrcon -H 127.0.0.1 -P 25575 -p s3cret list. In Docker, do not publish port 25575 to the host at all; run mcrcon inside the same container or on the same Docker network, which most Minecraft images make easy because they bundle mcrcon or an equivalent. Other games use their own keys (rcon_password in Source servers' server.cfg, a --rcon-port flag on Factorio) but the client side is identical.
Three things worth scripting
Safe backups are the classic. Minecraft writes chunks lazily, so copying the world directory under a running server produces a corrupt snapshot some fraction of the time. The fix is a 4-line wrapper:
mcrcon -H 127.0.0.1 -P 25575 -p "$MCRCON_PASS" "save-off" "save-all flush"
restic backup /srv/minecraft/world
mcrcon -H 127.0.0.1 -P 25575 -p "$MCRCON_PASS" "save-on"
Scheduled restarts with warnings are the second: a cron job that sends say Restart in 5 minutes, sleeps, sends the 1-minute warning, then stop, with systemd bringing the server back. The third is the whitelist and ops management from a Discord bot or a web form: whitelist add, kick, ban are one-liners, which is why the bot ecosystem around Minecraft is mostly thin wrappers over this protocol.
None of this needs a panel, and on a server that only you administer the whole management layer can be three shell scripts and a cron tab.
RCON is plaintext, so keep it off the internet
The protocol sends the password and every command unencrypted. Never forward port 25575 through your router, never bind it to a public interface, and treat the password as equivalent to shell access on the server, because op and console commands are exactly that. The safe patterns are: bind RCON to 127.0.0.1 and run mcrcon locally; run it over an SSH session; or reach it across a mesh VPN. If a hosting panel promises "RCON from anywhere," check that it means a TLS-wrapped web console rather than the raw port.
When a panel makes more sense
The moment two people administer the server, or you host more than one game, the CLI stops scaling. Crafty Controller gives Minecraft a web UI with scheduled backups, restarts and a console for several servers. Pterodactyl and PufferPanel do the same across many games with per-user permissions. Every one of them still speaks RCON underneath, and mcrcon remains the quickest way to debug when the panel says the server is unreachable. The game engines category lists the panels and the server images together.
What I'd do
Install mcrcon from your distro or build it with make from the repository, bind RCON to localhost, put the password in an environment file readable only by root, and write the backup wrapper above this week. Run that under cron with restic to off-site storage, and you have solved the most common way Minecraft worlds get lost. Add Crafty Controller only when a second admin asks for a button.
Similar game engines & frameworks apps
PixiJS
Game Engines & FrameworksFast 2D WebGL rendering engine for browser games
Replaces Adobe Animate runtime
Phaser
Game Engines & FrameworksFast HTML5 game framework for browser games you host yourself
Replaces Construct, GameMaker
OpenRA
Game Engines & FrameworksOpen-source remake of classic RTS games
Replaces Command & Conquer, Red Alert
PlayCanvas Engine
Game Engines & FrameworksOpen-source WebGL game engine for 3D browser games
Replaces Unity WebGL
openage
Game Engines & FrameworksOpen-source engine reimplementation of Age of Empires II
Replaces Age of Empires II original engine
Retroarch Web Player
Game Engines & FrameworksEmulate videogames system and play videogames through your web browser