> ## Documentation Index
> Fetch the complete documentation index at: https://help.freakhosting.com/llms.txt
> Use this file to discover all available pages before exploring further.

# L4D2 Server Commands and Cvars (Console List)

> L4D2 server commands and cvars: changelevel, status, kick, banid, z_difficulty, mp_gamemode, sv_consistency and more, with campaign map names for your console.

Left 4 Dead 2 server commands are typed in the Game Panel **Console** without a slash, or from your game with `rcon <command>` after `rcon_password`. The ones you use most are `changelevel <map>` to change the map, `status` to list players, `kick <name>` to remove someone and `z_difficulty <Easy|Normal|Hard|Impossible>` to set the difficulty. Settings you want to keep go in `server.cfg`.

## How to run L4D2 server commands

| Where | How |
| - | - |
| Panel **Console** | Type the command and press Enter, for example `changelevel c2m1_highway`. |
| Your game (RCON) | Type `rcon_password <password>`, then `rcon <command>`. |
| Permanent | Add the line to `server.cfg` (**Game settings** > **server.cfg: open the raw file**). |

A console command lasts until the next restart or map change. Many options also have a switch in **Game settings**, which is easier.

## Map and campaign commands

| Command | What it does |
| - | - |
| `changelevel <map>` | Changes the server to that map, for example `changelevel c5m1_waterfront`. |
| `map <map>` | Starts the map from scratch. |
| `maps *` | Lists every map on the server, including custom campaigns. |

## Player commands

| Command | What it does |
| - | - |
| `status` | Lists connected players with user ID and SteamID. |
| `kick <name>` | Kicks a player by name. |
| `kickid <userid> [message]` | Kicks by user ID from `status`, with an optional message. |
| `banid <minutes> <userid or SteamID>` | Bans a player; `0` minutes is permanent. |
| `writeid` | Saves the ban list so bans stay after a restart. |
| `say <text>` | Sends a chat message from the server. |

## Game and server cvars

| Cvar | Values | Panel setting |
| - | - | - |
| `hostname "<name>"` | Server name | **Server name** |
| `sv_password "<password>"` | Join password; empty for public | **Server password** |
| `rcon_password "<password>"` | RCON password | **RCON password** |
| `z_difficulty` | `Easy`, `Normal`, `Hard`, `Impossible` | **Difficulty** |
| `mp_gamemode` | `coop`, `realism`, `versus`, `survival`, `scavenge` | — (add to `server.cfg`) |
| `sv_allow_lobby_connect_only` | `1` lobby only, `0` allows `connect` | **Lobby only** |
| `sv_steamgroup` | Steam group ID | **Steam group** |
| `sv_steamgroup_exclusive` | `1` group members only when empty | **Steam group only** |
| `sv_cheats` | `0` or `1`; with `1` every player can use cheat commands | **Cheats** |
| `sv_consistency` | `1` checks critical files, `0` allows modded files | **Consistency Check (sv\_consistency)** in **Startup**; a `server.cfg` line overrides it |
| `sv_pure` | File purity level used by competitive configs | — |
| `sv_logbans` | `1` writes bans to the server log | **Log bans** |
| `mapcyclefile` | Map cycle text file | **Map cycle file** |
| `decalfrequency` | Seconds between player sprays | — |

## Campaign start maps

| Campaign | First map |
| - | - |
| Dead Center | `c1m1_hotel` |
| Dark Carnival | `c2m1_highway` |
| Swamp Fever | `c3m1_plankcountry` |
| Hard Rain | `c4m1_milltown_a` |
| The Parish | `c5m1_waterfront` |
| The Passing | `c6m1_riverbank` |
| The Sacrifice | `c7m1_docks` |
| No Mercy | `c8m1_apartment` |
| Crash Course | `c9m1_alleys` |
| Death Toll | `c10m1_caves` |
| Dead Air | `c11m1_greenhouse` |
| Blood Harvest | `c12m1_hilltop` |
| Cold Stream | `c13m1_alpinecreek` |
| The Last Stand | `c14m1_junkyard` |

Type `maps *` if a name doesn't work; it shows the exact names on your server.

## Frequently asked questions

### How do I change the map on my L4D2 server?

Type `changelevel <map>` in the **Console**. To start on that map every time, set **Start map** in **Game settings**.

### How do I give myself admin commands?

Vanilla Left 4 Dead 2 only has RCON. For an in-game admin menu, install SourceMod. See [SourceMod admin menu basics](https://help.freakhosting.com/games/left-4-dead-2/sourcemod-admin-menu-basics.md).

### Why does my console change disappear?

Console changes last until the next restart. Add the line to `server.cfg` to keep it.

### How do I ban someone permanently?

Find their user ID with `status`, type `banid 0 <userid>`, then `writeid`.

## Related guides

> **[Left 4 Dead 2 server guide](https://help.freakhosting.com/games/left-4-dead-2/left-4-dead-2-server-hosting-guide.md)**
>
> Every Left 4 Dead 2 page in one place.

> **[Fix consistency errors](https://help.freakhosting.com/games/left-4-dead-2/fixing-consistency-errors.md)**
>
> sv\_consistency explained.

> **[Vote settings](https://help.freakhosting.com/games/left-4-dead-2/configuring-vote-permissions.md)**
>
> sv\_vote\_\* cvars.

> **[SourceMod admin menu](https://help.freakhosting.com/games/left-4-dead-2/sourcemod-admin-menu-basics.md)**
>
> sm\_kick, sm\_ban and the admin menu.

> **[Use the server console](https://help.freakhosting.com/portals/game-panel/how-to-use-the-server-console.md)**
>
> Send commands from the panel.

***

> [!NOTE]
>
> **Tested by the FREAKHOSTING team** on 30 October 2026 (Left 4 Dead 2 on our Game Panel). Steps may differ slightly if the game changes.

> [!NOTE]
>
> ### Need Extra Help?
>
> If you encounter any issues, our support team is ready to assist:
>
> * **Live Chat:** Quick assistance via our website.
> * **Support Ticket:** [Open a Ticket](https://freakhosting.com/clientarea/submitticket.php)
> * **Discord:** [Join our Community](https://discord.gg/freakhosting)
> * **Email:** [support@freakhosting.com](mailto:support@freakhosting.com)

> [!TIP]
>
> ### Save on Your Hosting
>
> Ready to upgrade your hosting? Use code **KB20** at checkout for **20% off** your first order!

***

**Last Updated:** October 2026


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.