This guide walks you through setting up and configuring your Counter-Strike 2 dedicated server hosted on Legion Hosting, including GSLT registration, server.cfg configuration, game mode selection, workshop maps, plugin frameworks, and how to connect.
Step 1: Get a Game Server Login Token (GSLT)
A GSLT is a unique token that ties your CS2 server to your Steam account. You need a Steam account in good standing (no VAC bans) to generate one.
- Log in to your Steam account and visit steamcommunity.com/dev/managegameservers.
- In the App ID field enter
730(Counter-Strike 2). - Enter an optional memo (e.g.
Legion CS2 Server) to help you identify the token later. - Click Create. Copy the generated token — it looks like a long alphanumeric string.
- In GPanel, open your server's Startup tab and paste the token into the GSLT / Steam Token field.
Step 2: Start Your Server
In GPanel, navigate to your CS2 server and click Start. The server installs or verifies game files on first launch — this can take several minutes. Watch the console for the line:
Connection to Steam servers successful.
If you see that line, your GSLT is valid and the server is running in secure (VAC) mode.
Check GPanel's Network tab for your server's assigned game port and GOTV port. See How to Find Your Server IP and Port if you are unsure of your server's address.
Step 3: Configure server.cfg
The primary configuration file for your CS2 server is located at:
game/csgo/cfg/server.cfg
You can edit this file using the File Manager in GPanel or by uploading it over SFTP. See How to Upload Files via SFTP for instructions.
Below is a recommended starting configuration with explanations for each setting:
// -----------------------------------------------
// Basic server identity
// -----------------------------------------------
hostname "My CS2 Server" // Name shown in server browser
sv_password "" // Leave blank for public, set a password to restrict access
sv_cheats 0 // 0 = cheats off (required for VAC)
// -----------------------------------------------
// Player limits and regions
// -----------------------------------------------
maxplayers 10 // Max players (competitive: 10, casual up to 20)
sv_region 255 // 255 = world, 0 = US East, 3 = Europe
// -----------------------------------------------
// Rates (modern CS2 defaults are usually fine)
// -----------------------------------------------
sv_minrate 0
sv_maxrate 0 // 0 = unlimited
sv_mincmdrate 64
sv_maxcmdrate 128
sv_minupdaterate 64
sv_maxupdaterate 128
// -----------------------------------------------
// Game behaviour
// -----------------------------------------------
sv_alltalk 0 // 0 = teams only, 1 = all players hear all chat
sv_deadtalk 1 // Dead players can talk to living teammates
mp_autoteambalance 1
mp_limitteams 1
// -----------------------------------------------
// Execute game mode config last
// -----------------------------------------------
exec gamemode_competitive.cfg
Step 4: Game Types and Modes
CS2 uses a combination of two cvars to define the game mode. Set these in your startup parameters (GPanel Startup tab) or at the top of server.cfg.
| Mode | game_type | game_mode | Built-in exec |
|---|---|---|---|
| Casual | 0 |
0 |
gamemode_casual.cfg |
| Competitive | 0 |
1 |
gamemode_competitive.cfg |
| Wingman (2v2) | 0 |
2 |
gamemode_competitive2v2.cfg |
| Deathmatch | 1 |
2 |
gamemode_deathmatch.cfg |
| Arms Race | 1 |
0 |
gamemode_armsrace.cfg |
game_type and game_mode in GPanel's Startup parameters as launch arguments: +game_type 0 +game_mode 1. Changing them only in server.cfg without a restart may not take full effect.
Step 5: Map Pool and Map Changes
Use the following console commands to manage maps. These can be placed in server.cfg, typed via RCON, or run from the GPanel console.
Official Maps
CS2 ships with the standard competitive map pool. Change map with:
changelevel de_mirage
changelevel de_dust2
changelevel de_inferno
changelevel de_nuke
changelevel de_overpass
changelevel de_ancient
changelevel de_anubis
Workshop Maps
To run Steam Workshop maps your server needs the +host_workshop_map launch parameter and a Steam Web API key.
- Get a Steam Web API key from steamcommunity.com/dev/apikey.
- In GPanel's Startup tab add:
+sv_setsteamaccount YOUR_GSLT +authkey YOUR_WEBAPI_KEY - To load a workshop map, add:
+host_workshop_map WORKSHOP_MAP_ID(the numeric ID from the workshop URL). - Alternatively use:
+host_workshop_collection COLLECTION_IDto load an entire collection and cycle through it.
Step 6: MetaMod and CounterStrikeSharp (Plugin Framework)
MetaMod:Source is a plugin loader that sits between the CS2 game engine and plugins. CounterStrikeSharp (CSS) is a C# plugin framework built on top of MetaMod that lets you install community plugins such as admin menus, practice modes, and match management systems like Get5.
Installing MetaMod:Source
- Download the latest CS2-compatible MetaMod:Source build from sourcemm.net. Choose the master branch.
- Extract the archive. You will get an
addons/folder. - Upload the
addons/folder to your server'sgame/csgo/directory so the path becomesgame/csgo/addons/metamod/. See How to Upload Files via SFTP. - In
game/csgo/gameinfo.gi, find theSearchPathsblock and add the following line directly above the firstGameentry:Game csgo/addons/metamod - Restart your server. Run
meta listin the GPanel console — if MetaMod is loaded you will see its version listed.
Installing CounterStrikeSharp
- Download the latest release from github.com/roflmuffin/CounterStrikeSharp. Get the with-runtime package so you do not need to install .NET separately.
- Extract and upload the contents to
game/csgo/(merging with the existingaddons/folder). - Restart the server. Check the console for
[CounterStrikeSharp] Loaded successfully. - Individual plugins go in
game/csgo/addons/counterstrikesharp/plugins/— each plugin has its own subfolder.
Step 7: Connecting to Your Server
Find your server's IP address and assigned port on the Network tab in GPanel.
Via In-Game Console
Open the developer console with the ` (tilde) key and type:
connect YOUR.SERVER.IP:PORT
If you set an sv_password, follow up with:
password YourPassword
Via Server Browser
- In CS2, open Play > Community Server Browser.
- Click the Favourites tab, then Add a server.
- Enter your server IP and port (from GPanel's Network tab) and click OK.
- Your server will appear in Favourites and you can double-click to join.
Via Steam Connect Link
You can share a direct Steam connect link with players:
steam://connect/YOUR.SERVER.IP:PORT/YourPassword
Paste this link into a browser address bar or a Steam chat message. The password part is optional if the server has none.
YOUR.SERVER.IP:PORT with your actual server IP and port from GPanel's Network tab. See How to Find Your Server IP and Port for help locating it.
Related Articles
- CS2 Admin Setup — RCON, admin commands, competitive config, GOTV
- CS2 Troubleshooting — GSLT errors, crashes, connection issues, plugin problems
- How to Find Your Server IP and Port
- How to Upload Files via SFTP