4 min readUpdated Aug 15, 2026

L4D2 Console Commands List

Left 4 Dead 2 hands most of the pacing to the AI Director, and the Director is driven entirely by console variables. The director_ family decides when hordes and bosses spawn, and the z_ family sets the infected themselves, from common horde limits to Tank and Witch health.

Search the full list below, then add what you need to your Left 4 Dead 2 server. Each entry shows the default value, what it does and whether it runs on the server or the client.

Category

2,067 commands in total

CommandDefaultDescription
Erases current game stats and writes out a blank stats fileCommandServer
Shutdown and restart the engine.CommandServer
Default: 0Turn on achievement debug msgs.ServerCheatReplicated
Default: 0Turn off achievements.ServerCheatReplicated
Default: 1No description is published for this one.ServerCheat
Add an IP address to the ban list.CommandServer
Default: 0Percent of normal backpack item use duration to use when affected by AdrenalineServerCheatReplicated
Default: 15No description is published for this one.ServerCheatReplicated
Default: 25No description is published for this one.ServerCheatReplicated
Default: 0Percent of normal revive duration to use when affected by AdrenalineServerCheat
Default: 260No description is published for this one.ServerCheatReplicated
Default: 0NPC Line-Of-Sight debug mode. If 1, solid entities that block NPC LOC will be highlighted with white bounding boxes. If 2, it'll show non-solid entities that would do it if they were solid.ServerCheat
Default: 0No description is published for this one.ServerCheatReplicated
Default: 1Set to 0 to disable TLK_IDLEs on survivorsServerCheat
Changes the density of air for drag computations.CommandServer
Alias a command.CommandServer
Default: 0No description is published for this one.ServerCheatReplicated
Default: 3No description is published for this one.ServerCheatReplicated
No description is published for this one.CommandServer
No description is published for this one.CommandServer
Add a user ID to the ban list.CommandServer
Add an IP address to the ban list.CommandServer
Ends gathering of info.CommandServer
Starts gathering of info. Arguments: filename to write results intoCommandServer
Bind a key.CommandServer
Performs a bind <key> 'increment var <cvar> 0 1 1'CommandServer
Dump the contents of the blackboxCommandServer
Record an entry into the blackboxCommandServer
Default: 1How long an out-of-range Boomer will tolerate being visible before fleeingServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 4Amount of damage done by a PZ boomer's regular melee attackServerCheatReplicated
Default: 1How long the Boomer waits before he vomits on his target on Normal difficultyServerCheat
Default: 0Force all bots to crouch.ServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 0Bot uses usercmd of player by index.ServerCheatReplicated
Default: 180Offsets the bot yaw.ServerCheat
Default: 0Toggle. Player takes damage but won't die. (Shows red cross when health is zero)ServerCheatNotify
Turn a budget group on/offCommandServer
Automatically swaps the current weapon for the bug bait and back again.CommandServer
cache_print [section] Print out contents of cache memory.CommandServer
cache_print_lru [section] Print out contents of cache memory.CommandServer
cache_print_summary [section] Print out a summary contents of cache memory.CommandServer
Start a vote on an issue.CommandServer
Tests hull collision detectionCommandServer
Tests collision detectionCommandServer
Write all convars to file.CommandServer
Spawn airboat in front of the player.CommandServer
Spawn jeep in front of the player.CommandServer
Default: 30No description is published for this one.ServerCheat
Default: 50No description is published for this one.ServerCheat
Default: 400No description is published for this one.ServerCheat
Default: 500No description is published for this one.ServerCheat
Default: 100No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheatReplicated
Default: 0No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheat
changelevel <mapname> :Multiplayer change level.CommandServer
Default: 0No description is published for this one.ServerCheat
Default: 8No description is published for this one.ServerCheat
Transition to the specified map in single playerCommandServer
Default: 10Amount of damage done by a PZ charger's regular melee attackServerCheatReplicated
Default: 1Enable/disable clock correction on the client.Cheat
Default: 200Sets the maximum number of milliseconds per second it is allowed to correct the client clock. It will only correct this amount if the difference between the client and server clock is equal to or larger than cl_clock_correction_adjustment_max_offset.Cheat
Default: 90As the clock offset goes from cl_clock_correction_adjustment_min_offset to this value (in milliseconds), it moves towards applying cl_clock_correction_adjustment_max_amount of adjustment. That way, the response is small when the offset is small.Cheat
Default: 10If the clock offset is less than this amount (in milliseconds), then no clock correction is applied.Cheat
Default: 999Force clock correction to match the server tick + this offset (-999 disables it).Cheat
Default: 0Show debugging info about the clock drift.Cheat
Default: 150Maximum number of milliseconds the clock is allowed to drift before the client snaps its clock to the server's.Cheat
Default: 0Maximum number of milliseconds the clock is allowed to drift before the client snaps its clock to the server's.Cheat
Default: 6Delay in seconds before the client will resend the 'connect' attemptServer
Default: 0Set to 1 to skip any models that don't go through the model fast pathCheat
Default: 240Force with witch the claw shoves other zombies awayServerCheatReplicated
Default: 52Range of the Claw weaponServerCheatReplicated
Default: 70Range of the Claw weapon when looking straight down, so it can reach your feet from your eyes.ServerCheatReplicated
Default: 0No description is published for this one.ServerCheatReplicated
Default: 1No description is published for this one.ServerCheatReplicated
Default: 0No description is published for this one.ServerCheatReplicated
Remove given attribute from all areas in the selected set.CommandServer
clears debug overlaysCommandServer
Default: 0Chance to replenish wanderers in cleared nav areasServerCheat
Default: 27005If non-zero, client binds port to specific address. Usually you should leave this blank to use a different random system-assigned port for each connection.Server
Default: 0Enable close captioning.Archived
Forward command to server.CommandServer
sets userinfo string for split screen player in slot 1CommandServer
sets userinfo string for split screen player in slot 2CommandServer
sets userinfo string for split screen player in slot 3CommandServer
sets userinfo string for split screen player in slot 4CommandServer
Default: 1No description is published for this one.ServerCheatReplicated
Default: 75No description is published for this one.ServerCheatReplicated
Default: 0No description is published for this one.ServerCheatReplicated
Collect model names of the entities you're pointing atCommandServer
Tests collision systemCommandServer
No description is published for this one.CommandServer
No description is published for this one.CommandServer
Cause the engine to crash (Debug!!)CommandServer
No description is published for this one.CommandServer
Create a prediction errorCommandServer
Marks a player as the VIPCommandServer
Default: -2cs_ShowStateTransitions <ent index or -1 for all>. Show player state transitions.ServerCheat
Reports the flow distance for the local playerCommandServer
Show the list of convars/concommands.CommandServer
Add a line to the debug history. Format: <category id> <line>CommandServer
Dump the debug history to the console. Format: <category id> Categories: 0: Entity I/O 1: AI Decisions 2: Scene Print 3: Alyx Blind 4: Log of damage done to...CommandServer
Default: 0No description is published for this one.ServerCheat
Default: 3No description is published for this one.ServerCheat
Default: 3No description is published for this one.ServerCheatReplicated
Used by the devshots system to go to the next map in the devshots maplist.CommandServer
Show all convars which are not at their default values (optional restricted to specific flags).CommandServer
Default: 6Items per 100 yards squareServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 6Items per 100 yards squareServerCheat
Begin a director scriptCommandServer
Default: 15No description is published for this one.ServerCheat
Default: 2No description is published for this one.ServerCheat
Default: 10No description is published for this one.ServerCheat
Default: -1Items per 100 yards square (-1 to spawn all)ServerCheat
Default: 1No description is published for this one.ServerCheat
Default: 50No description is published for this one.ServerCheat
Default: 25No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 10No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 0No description is published for this one.ServerCheat
Default: 6Items per 100 yards squareServerCheat
End a director scriptCommandServer
Default: 3How many clusters of items will be populated in the finaleServerCheat
Default: 2No description is published for this one.ServerCheat
Default: 5No description is published for this one.ServerCheat
Default: 0Forces background map population logic for testingServerCheat
Forces a 'PanicEvent' to occurCommandServer
Force the specified scripted panic event to happenCommandServer
Default: 0No description is published for this one.ServerCheat
Force start the versus game, so PZs can spawn even if survivors are still in the safe roomCommandServer
Default: 0No description is published for this one.ServerCheat
Default: 6Items per 100 yards squareServerCheat
Default: 5If you don't cross the movement threshold in DirectorGauntletMovementTimer seconds, you will get this much bonus time added...ServerCheat
Default: 30Maximum amount of bonus time you can accumulate from not moving.ServerCheat
Default: 500If you move less than this in DirectorGauntletMovementTimer seconds, you will get an increasing break between mobs.ServerCheat
Default: 10If you don't cross the movement threshold in this amount of time, you get increasing break time added between mobs.ServerCheat
Default: 3000How far you have to progress after a gauntlet tank spawn before the horde fires up again.ServerCheat
Default: 3000No description is published for this one.ServerCheat
Default: 0All survivors must be below this intensity during RELAX for wandering zombies to be spawnedServerCheat
Default: 0All survivors must be below this intensity during RELAX for wandering zombies to be spawnedServerCheat
Default: 0All survivors must be below this intensity during RELAX for wandering zombies to be spawnedServerCheat
Default: 0All survivors must be below this intensity before a Peak is allowed to switch to Relax (in addition to the normal peak timer)ServerCheat
Default: 0No description is published for this one.ServerCheatReplicated
Default: 50Scavenge items of the same kind that are this close to each other are considered a single 'cluster' for population purposesServerCheat

Or search above to jump straight to the one you need.

Values marked Server belong in your left4dead2/cfg/server.cfg. Values marked Clientare typed into each player’s own console.

How to Use L4D2 Server Commands

L4D2 reads left4dead2/cfg/server.cfg on startup and on every map change.

  1. 1
    Log in to Bropanel and select your L4D2 server.
  2. 2
    In the sidebar, open Files.
  3. 3
    Open left4dead2/cfg/server.cfg.
  4. 4
    Add one command per line, such as z_difficulty Hard.
  5. 5
    Save the file and restart your server.

Many Director values are flagged as cheats, so they need sv_cheats 1 before they take effect. Most servers use a plugin such as SourceMod to apply those instead of turning cheats on for everyone.

AI Director Commands

The Director is what makes each playthrough different. These variables change how hard it pushes.

CommandDefaultWhat it does
director_no_bosses0Set to 1 to stop Tank and Witch spawns.
director_no_mobs0Set to 1 to stop horde rushes.
director_no_specials0Set to 1 to stop special infected spawning.
director_force_tank0Forces a Tank to spawn.
director_force_witch0Forces a Witch to spawn.
director_finale_panic_waves2Panic waves per finale stage.
director_ammo_density6How much ammo the Director places.
director_adrenaline_density6How much adrenaline the Director places.
director_defibrillator_density6How many defibrillators the Director places.
director_ai_tanks0Set to 1 so Tanks are always AI controlled.

Infected and Survivor Commands

CommandDefaultWhat it does
z_difficultyNormalGame difficulty. Easy, Normal, Hard or Impossible.
z_common_limit30How many common infected exist at once.
z_witch_health1000Witch health.
sb_all_bot_game0Set to 1 to allow a server made only of bots.
vs_max_team_switches1Team switches allowed per player in Versus.

Caution

Raising z_common_limit puts real load on the server. Push it too far and everyone gets lag rather than a harder game.

Most Used L4D2 Server Commands

CommandDefaultWhat it does
hostnameemptySets the server name shown in the browser.
sv_passwordemptyLocks the server behind a password.
rcon_passwordemptySets the admin password for rcon.
sv_downloadurlemptyPoints clients at your FastDL host.
sv_gametypesemptyGame types the server allows.
sv_alltalk1Set to 0 so teams only hear their own side.
sv_cheats0Set to 1 to unlock cheat commands.
sv_lan0Set to 1 for a LAN only server.
sv_consistency1Enforces file consistency for critical files.
sv_region255Region reported to the server browser.
sv_steamgroup_exclusive0Restricts an empty server to your Steam group.

Setting the Game Mode

mp_gamemode does not appear in the list above because L4D2 sets it on the launch line rather than registering it like a normal variable. On Bropanel you pick the mode in Settings and the panel passes it through for you.

ModeValue
Campaigncoop
Versusversus
Survivalsurvival
Scavengescavenge
Realismrealism
Realism Versusmutation15

How to Open the Console in L4D2

  1. 1
    Open Left 4 Dead 2 and go to Options.
  2. 2
    Select Keyboard/Mouse.
  3. 3
    Set Allow Developer Console to Enabled.
  4. 4
    Press the ~ key in game to open it.

FAQ