A production-ready n8n community node for remote game server administration via RCON (Remote Console) protocol.
⚠️ Security Warning: RCON transmits passwords in plaintext over TCP. Only use this node in secure network environments with VPN connections, SSH tunnels, or when n8n runs on the same machine as your game server. Never expose RCON ports directly to the internet.
ℹ️ Self-Hosted Only: This node requires TCP socket access and can only be used with self-hosted n8n instances. It will not work on n8n Cloud.
Control and manage your game servers directly from n8n workflows - execute commands, retrieve status, automate server management, and integrate with other n8n nodes for powerful automation scenarios.
RCON Protocol is a network protocol for remote server administration in Source Engine games and other compatible game servers.
n8n is a fair-code licensed workflow automation platform.
- Features
- Installation
- Quick Start
- Usage Examples
- Supported Games & Servers
- Configuration Options
- Troubleshooting
- Security Warnings
- Error Handling
- Contributing
- Project Status
- License
- Acknowledgments
- Support
- Roadmap
- ✅ Multiple Protocol Support - Source RCON (TCP) and BattlEye RCON (UDP)
- 🎮 Wide Game Support - Minecraft, Source games (CS:GO, CS2, TF2), Rust, ARK, DayZ, ARMA 2/3, and more
- 🔒 Secure Authentication - Password-based authentication with proper error handling
- 📦 Multi-Packet Responses - Correctly handles responses larger than 4KB (Source RCON)
- ⚡ Async Operation - Non-blocking command execution
- 🛡️ Type-Safe - Built with TypeScript for reliability
- ⏱️ Configurable Timeouts - Customize connection and I/O timeouts
- 🎪 Error Handling - Comprehensive error types with
continueOnFailsupport - 🔄 Workflow Integration - Seamlessly integrate server management into n8n workflows
- 🎯 BattlEye Support - Full UDP-based protocol with CRC32 validation and heartbeat
- In n8n, go to Settings > Community Nodes
- Click Install a community node
- Enter:
n8n-nodes-rcon - Click Install
cd ~/.n8n/nodes
npm install n8n-nodes-rconRestart n8n to load the new nodes.
After installation, look for the RCON node in the nodes panel under the "Transform" category.
Before using the RCON node, you need to configure credentials:
- Open any workflow in n8n
- Add the RCON node to your workflow
- Click on Credential to connect with
- Click Create New
- Fill in the connection details:
- Protocol: Select protocol type (Source RCON for most games, BattlEye RCON for DayZ/ARMA)
- Host: Your server's IP address or hostname (e.g.,
192.168.1.100orgame.example.com) - Port: RCON port (Source:
25575for Minecraft,27015for Source games; BattlEye: typically game port like2305for DayZ) - Password: Your RCON password
- Connection Timeout: Optional, defaults to 5000ms
- Add the RCON node to your workflow
- Select your configured credentials
- Choose operation: Send Command
- Enter a command (e.g.,
listfor Minecraft) - Execute the workflow
Create a workflow that checks your Minecraft server status every 5 minutes:
Schedule Trigger (every 5 min)
→ RCON: "list"
→ IF (player count > 0)
→ Send notification to Discord/Slack
Announce scheduled maintenance to players:
Schedule Trigger (specific time)
→ RCON: "say Server restart in 30 minutes"
→ Wait 15 minutes
→ RCON: "say Server restart in 15 minutes"
→ Wait 10 minutes
→ RCON: "say Server restart in 5 minutes"
→ Wait 5 minutes
→ RCON: "stop"
Allow external systems to trigger server commands:
Webhook Trigger
→ Function: Validate request
→ RCON: Execute command from webhook payload
→ Respond to webhook with result
Create backups before executing maintenance commands:
Schedule Trigger
→ RCON: "save-off" (disable autosave)
→ RCON: "save-all" (force save)
→ Execute File Operations: Backup world files
→ RCON: "save-on" (enable autosave)
→ Send notification: Backup complete
Adjust server settings based on time of day:
Schedule Trigger (every hour)
→ Get Current Time
→ Switch (time-based):
Case "Night (00:00-06:00)":
→ RCON: "difficulty peaceful"
Case "Day (06:00-22:00)":
→ RCON: "difficulty normal"
Case "Prime Time (18:00-22:00)":
→ RCON: "difficulty hard"
- Protocol: Source RCON
- Default Port: 25575
- Example Commands:
list,say <message>,give <player> <item>,weather clear,time set day
- Protocol: Source RCON
- Default Port: 27015
- Supported: CS:GO, Counter-Strike 2, Team Fortress 2, Garry's Mod, Left 4 Dead 2
- Example Commands:
status,changelevel <map>,kick <player>,sv_cheats <0|1>
- Protocol: Source RCON
- Default Port: 28016
- Example Commands:
save,quit,global.ban <player>,weather.rain 0
- Protocol: Source RCON
- Default Port: 27020
- Example Commands:
SaveWorld,DestroyWildDinos,Broadcast <message>
- Eco
- Conan Exiles
- 7 Days to Die
- Satisfactory
- Space Engineers
- Valheim (with mods)
- Protocol: BattlEye RCON
- Default Port: 2305 (or game port)
- Example Commands:
players,kick <player>,say -1 <message>,loadScripts,#shutdown
- Protocol: BattlEye RCON
- Default Port: 2302 (or game port)
- Example Commands:
players,kick <player>,admins,missions
- Protocol: BattlEye RCON
- Default Port: 2302 (or game port)
- Example Commands:
players,kick <player>,say -1 <message>,loadScripts
- Protocol: BattlEye RCON
- Default Port: 2001 (or game port)
- Example Commands:
players,kick <player>,say -1 <message>
| Parameter | Description | Required |
|---|---|---|
| Command | The RCON command to execute | Yes |
| Field | Type | Default | Description |
|---|---|---|---|
| Host | String | - | Server hostname or IP address |
| Port | Number | 25575 | RCON port number |
| Password | String | - | RCON password (stored encrypted) |
| Connection Timeout | Number | 5000 | Connection timeout in milliseconds |
Problem: "Connection timeout" or "Connection failed"
Solutions:
- Verify the server is running and accessible
- Check firewall rules allow connections to the RCON port
- Ensure the RCON port is correctly configured in server.properties
- Try increasing the connection timeout in credentials
Problem: "Authentication failed - incorrect password"
Solutions:
- Double-check your RCON password
- Ensure RCON is enabled on the server
- Check for typos or extra spaces in the password field
- Verify the password in your server configuration file
Warning: Multiple failed authentication attempts may result in a temporary IP ban!
Problem: "Command failed" or empty responses
Solutions:
- Verify the command syntax is correct for your game/server
- Check if you have permission to execute the command
- Some commands may not return output (this is normal)
- Use
continueOnFailoption if commands may legitimately fail
Problem: Truncated or incomplete responses
Solution: This node automatically handles multi-packet responses. If you're still experiencing issues:
- Increase the I/O timeout in your credentials
- Check your network connection stability
- Report the issue with server type and command details
Problem: RCON node doesn't appear after installation
Solutions:
- Restart n8n:
sudo systemctl restart n8n - Clear browser cache and reload
- Check n8n logs for installation errors:
~/.n8n/logs/ - Reinstall the node:
npm uninstall n8n-nodes-rcon && npm install n8n-nodes-rcon
- 🐛 Bug Reports: GitHub Issues
- 💡 Feature Requests: GitHub Issues
- 💬 Questions: GitHub Discussions
- 📖 n8n Community: n8n Forum
The RCON protocol transmits passwords in plaintext over TCP. This is the most important security consideration.
Recommended secure configurations:
- ✅ Best: Run n8n on the same machine as your game server (localhost connection)
- ✅ Good: Use VPN connections to your game servers
- ✅ Good: Use SSH tunneling for remote connections (ssh -L port forwarding)
- ✅ Keep RCON ports firewalled and only accessible from trusted IPs
- ❌ NEVER expose RCON ports directly to the internet
- ❌ NEVER use RCON over untrusted networks without encryption
After multiple failed authentication attempts, the server will ban your IP address:
- Use strong, correct passwords
- Test credentials before deploying workflows
- Consider the impact of workflow errors that retry authentication
- Use long, random passwords (20+ characters)
- Never use the same password as other server credentials
- Store passwords securely in n8n (they are encrypted at rest)
- Rotate passwords regularly
- Validate and sanitize any user input used in commands
- Be cautious with commands that can modify server state
- Use workflow permissions to restrict who can execute server commands
- Log all command executions for audit purposes
- Restrict access to n8n workflows containing RCON nodes
- Use webhook authentication for external triggers
- Enable n8n audit logging
- Keep n8n and this node updated to the latest versions
The RCON node supports n8n's continueOnFail option. When enabled, execution errors won't stop the workflow:
// Success response
{
"command": "list",
"response": "There are 3 players online: Alice, Bob, Charlie",
"success": true,
"timestamp": "2025-10-30T22:15:00.000Z"
}
// Error response (with continueOnFail enabled)
{
"error": "Connection timeout",
"success": false,
"timestamp": "2025-10-30T22:15:00.000Z"
}Contributions are welcome! Here's how you can help:
- Report Bugs: Open an issue with details about the problem
- Suggest Features: Share your ideas for improvements
- Submit Pull Requests: Follow the development setup below
# Clone the repository
git clone https://github.com/goevexx/n8n-nodes-rcon.git
cd n8n-nodes-rcon
# Install dependencies
npm install
# Build the project
npm run build
# Run tests
npm test
# Lint and format code
npm run lint
npm run formatThe repository includes Docker Compose configurations for local testing with real game servers:
# Start test environment (n8n + game servers)
docker-compose up -d
# Access n8n at http://localhost:9001Available Test Servers:
-
Source RCON (TCP) - Minecraft Server
- Host:
minecraft-rcon-test - Port:
25575 - Password:
minecraft_rcon_password - Protocol: Source RCON (TCP)
- Host:
-
BattlEye RCON (UDP) - Authentic Protocol Implementation
- Host:
battleye-rcon-test - Port:
2305 - Password:
dayz_rcon_password - Protocol: BattlEye RCON (UDP)
- Implements the complete BattlEye RCON protocol with CRC32 validation, sequence numbers, and heartbeat
- Compatible with DayZ, ARMA 2, ARMA 3, Arma Reforger protocol specs
- Responds to standard commands like
players, empty heartbeat commands
- Host:
Both test servers implement authentic protocol specifications and can be used to verify RCON functionality without needing external game servers.
n8n-nodes-rcon/
├── credentials/
│ └── RconApi.credentials.ts # Credential type definition
├── nodes/
│ └── Rcon/
│ ├── Rcon.node.ts # Main node implementation
│ ├── RconClient.ts # RCON protocol client
│ ├── RconTypes.ts # TypeScript types
│ ├── helpers.ts # Helper functions
│ └── rcon.svg # Node icon
├── src/
│ └── index.ts # Package exports
├── dist/ # Compiled JavaScript (generated)
└── README.md
This project is actively maintained. Current focus:
- ✅ Core RCON protocol implementation complete
- ✅ Full multi-packet response handling
- ✅ Production-ready error handling
- 🔄 Adding more usage examples
- 🔄 Expanding test coverage
- 📋 Planning additional features
See ROADMAP.md for detailed plans.
MIT - Free to use, modify, and distribute.
- Built for the n8n community
- Based on Source RCON Protocol Specification by Valve
- Thanks to all contributors and users
Need help? Here's how to get support:
Future enhancements being considered:
- Additional operations (batch commands, server info)
- Connection pooling for high-volume workflows
- UDP RCON support (for GoldSrc games)
- Challenge protocol support
- Retry mechanism with exponential backoff
- Server status monitoring operation
- Multi-server operation support
Built with ❤️ for the n8n and gaming communities