Left 4 Dead 2 Server Admin, RCON & Director Commands: Console Reference
Every Left 4 Dead 2 admin command an operator needs over RCON: enable RCON and a GSLT, switch game modes and mutations, change maps without dropping players, kick and ban (and actually make bans survive a restart), tune difficulty, control the AI Director, open the server to direct connections, and run SourceMod - plus the L4D2-specific traps: sv_cheats silently reverting on lobby-reserved servers, timed bans never persisting, and versus difficulty being hardcoded.
Left 4 Dead 2 dedicated servers use the standard Valve Source RCON protocol - the same one Counter-Strike and Team Fortress 2 use - so any Source RCON client works. But L4D2 layers its own quirks on top: lobby reservation that fights your cvars, an AI Director behind sv_cheats, and ban persistence rules that most guides get wrong. This reference covers the confirmed behavior.
Enabling RCON
RCON rides the game port (default 27015, TCP) - there is no separate RCON port. Enable it by setting a password in left4dead2/cfg/server.cfg:
rcon_password "your_strong_password"
Then from a client console: rcon_address <ip>:27015, rcon_password <password>, and prefix commands with rcon (e.g. rcon status). Dedicated RCON tools skip the prefix.
GSLT required for public servers.
Since ~2020 a public, internet-listed L4D2 server needs a Steam
Game Server Login Token
(create one at steamcommunity.com/dev/managegameservers with App ID
222840
, one token per server instance) supplied at launch, e.g.
+sv_setsteamaccount <token>
. Without it the server runs but is limited to LAN-style anonymous mode.
Game modes & mutations
The active mode is a single cvar:
mp_gamemode versus
Valid values: coop, realism, survival, versus, teamversus, scavenge, teamscavenge, and mutation IDs (mutation1 ... mutation20, community1 ... community6). Two related settings trip people up:
sv_gametypes is a comma-separated whitelist of which modes lobby matchmaking may place on your server. If versus is not in sv_gametypes, lobbies will never send you a versus game - a classic "my server only runs coop" cause.
Mutations can also be loaded directly with the map command: map c1m1_hotel mutation12 starts Realism Versus on Dead Center.
Changing maps: changelevel vs map
Command
Effect on connected players
changelevel <map>
Transitions the server to the new map keeping clients connected. Use this on a live server.
map <map> [mode]
Hard-resets the session and disconnects clients. Use for mode switches or a fresh start.
Map codes follow the c<campaign>m<chapter>_<name> pattern - c1m1_hotel (Dead Center), c2m1_highway (Dark Carnival), c5m1_waterfront (The Parish), c8m1_apartment (No Mercy). Run maps c in the console to list every installed campaign map rather than trusting a copied list - custom campaigns appear there too.
Player management
Run status first: it prints each player's name, userid, and Steam ID - the identifiers the moderation commands take.
Command
Syntax
Notes
kick
kick <name>
Kick by exact name.
kickid
kickid <userid> [reason]
Kick by userid from status - immune to name tricks.
banid
banid <minutes> <userid>
0 = permanent. Bans by Steam ID.
removeid
removeid <steamid>
Lift a Steam ID ban.
addip / removeip
addip <minutes> <ip>
IP ban / unban.
writeid / writeip
writeid
Write permanent bans to banned_user.cfg / banned_ip.cfg.
Ban persistence is stricter than other Source games' folklore suggests. Two confirmed traps:
Timed bans never persist.writeid writes only permanent (0-minute) bans to banned_user.cfg; a banid 60 ... ban lives in memory and dies with the server process no matter what you do.
Config order matters. Your server.cfg must exec banned_user.cfg and exec banned_ip.cfgbefore any writeid/writeip runs, or a fresh writeid overwrites the file and silently erases your existing ban list.
Difficulty
z_difficulty Impossible
Values: Easy, Normal, Hard, Impossible (Expert). Settable live over RCON, applies to coop, realism, and survival. In versus the difficulty is hardcoded to Normal - z_difficulty has no effect there, and changing it requires a SourceMod plugin. Versus team-switching is limited by vs_max_team_switches (default 1).
The AI Director and sv_cheats
Most Director and horde-tuning commands are cheat-flagged: director_stop, director_start, director_panic_forever, director_force_panic_event, director_no_survivor_bots, z_common_limit, z_mob_spawn_max. They require sv_cheats 1, which applies server-wide and lets every connected client use cheat commands too - not a live-public-server setting.
The L4D2-specific trap: on a lobby-reserved server, rcon sv_cheats 1 silently reverts to 0. The reservation logic re-asserts it. You must unreserve first (the common route is a SourceMod plugin providing sm_unreserve) or run the server unreserved (sv_allow_lobby_connect_only 0 and direct connects only).
One useful non-cheat distinction for filling seats: sb_add (spawn an extra survivor bot) is not cheat-flagged, while sb_takecontrol (possess a bot) is.
Direct connections & Steam group servers
Fresh L4D2 servers only accept lobby matchmaking traffic. To let players connect <ip> directly:
sv_allow_lobby_connect_only 0
To bind the server to your Steam group (members see it in the main menu's server list):
sv_steamgroup_exclusive has three levels, not two: 0 = public; 1 = a group member must be in the game before the public can fill it; 2 = fully excluded from matchmaking. Known engine bug: very large (newer) group IDs above ~16.7 million fail to register - an old datatype limit.
More than 8 players
There is no supported vanilla cvar for raising the 4-player coop / 8-player versus caps. Larger servers use the l4dtoolz plugin (a MetaMod:Source plugin) to unlock real slots, typically alongside a SourceMod bot/spawn plugin so extra joiners get a survivor instead of sitting in spectator. sv_visiblemaxplayers only changes the advertised count in the browser, not the real cap.
SourceMod essentials
Serious L4D2 communities run MetaMod:Source + SourceMod. Admins are declared in addons/sourcemod/configs/admins_simple.ini; admin actions work from the server console, RCON, or in-game chat (!kick / /kick):
Command
Purpose
sm_kick <target> [reason]
Kick via SourceMod (logged, immunity-aware).
sm_ban <target> <minutes> [reason]
Ban via SourceMod's ban system.
sm_cvar <cvar> <value>
Set a cvar - bypasses the cheat flag for most cheat-protected cvars (e.g. Director tuning) without turning on sv_cheats for clients. The exception is sv_cheats itself, which lobby reservation still re-asserts.
server.cfg essentials
hostname "My L4D2 Server"
rcon_password "your_strong_password"
sv_password "" // set to require a join password
motd_enable 1 // shows left4dead2/motd.txt on join
sv_region 3 // 0 US-East, 1 US-West, 2 S.America, 3 Europe,
// 4 Asia, 5 Australia, 6 Middle East, 7 Africa, 255 World
sv_tags "hidden:0" // browser tags; also the modern home of the old
// sv_search_key convention (use a "key:xxx" tag)
exec banned_user.cfg // BEFORE any writeid - see ban persistence above
exec banned_ip.cfg
server.cfg is re-executed on every map load (it is the servercfgfile default), so live cvar experiments get reset at the next transition unless you write them into the file.
Common mistakes
Assuming timed bans survive a restart. They never do - only permanent (banid 0 + writeid) bans persist.
writeid before exec banned_user.cfg in server.cfg - wipes the existing ban file.
Flipping sv_cheats 1 over RCON on a lobby-reserved server and concluding Director commands are broken - the reservation reverted it; unreserve first.
Setting z_difficulty for versus - versus is hardcoded to Normal; only coop/realism/survival respect it.
Using map on a live server for a simple rotation - it drops everyone; changelevel keeps them connected.
Editing mp_gamemode but not sv_gametypes - direct connects get the new mode, but lobbies still only send whitelisted modes.
Because Left 4 Dead 2 speaks genuine Valve Source RCON, MantaScope's web RCON connects to your server straight from the browser - send these commands, watch the live player list, and manage bans without a desktop tool - alongside population history, uptime tracking, scheduled restarts, and Discord alerts.
How to Play Black Ops 2 Online in 2026 (Plutonium Setup Guide)