Skip to main content
server.cfg is the heart of every FiveM server: it sets your server name, player slots, license key, which resources start, and in what order. This guide breaks the file down line by line so you know exactly what to change and what to leave alone. Edit it through the File Manager in the Wasabi Hosting Game Panel or via SFTP.

A Typical server.cfg

# Network endpoints — keep these as-is
endpoint_add_tcp "0.0.0.0:30120"
endpoint_add_udp "0.0.0.0:30120"

# Server identity
sv_hostname "My City RP | Serious Roleplay | discord.gg/mycity"
sets sv_projectName "My City RP"
sets sv_projectDesc "A serious roleplay community with custom jobs and vehicles."
sets locale "en-US"
sets tags "roleplay, economy, custom"

# Player slots
sv_maxclients 48

# License & API keys
sv_licenseKey "cfxk_xxxxxxxxxxxxxxxxxxxx_xxxxx"
set steam_webApiKey "YOURSTEAMWEBAPIKEY"

# Core settings
set onesync on
sv_enforceGameBuild 3095
sv_scriptHookAllowed 0

# Resources — order matters
ensure mapmanager
ensure chat
ensure spawnmanager
ensure sessionmanager
ensure basic-gamemode
ensure hardcap

# Permissions (see the Add Admins guide)
add_ace group.admin command allow
add_principal identifier.fivem:1234567 group.admin

Line-by-Line Breakdown

Network Endpoints

endpoint_add_tcp and endpoint_add_udp tell FXServer which IP and port to listen on. FiveM uses port 30120 (both TCP and UDP) by default. On Wasabi Hosting these are pre-configured to match your allocated port — don’t change them unless support tells you to, or the server will fail to bind.

Server Identity

SettingPurpose
sv_hostnameThe name shown in the in-game server list
sets sv_projectNameProject name shown prominently in the modern server list UI
sets sv_projectDescShort description shown under the project name
sets localeYour server’s primary language (e.g. en-US, de-DE)
sets tagsComma-separated keywords players can filter by

Player Slots

sv_maxclients sets the maximum number of players. Values above 48 require OneSync (see below). Keep the slot count realistic for your plan’s resources — more slots means more CPU and RAM usage.

License Key

sv_licenseKey is required — the server won’t start without a valid key. Generate one for free at the Cfx.re Keymaster (sign in, click New server, register your server’s IP, copy the key). One key is valid for one server at a time.

Steam Web API Key

set steam_webApiKey is optional but recommended: it enables Steam identifiers for players who launch through Steam, which many admin and whitelist scripts rely on. Create a free key at steamcommunity.com/dev/apikey.

OneSync

set onesync on enables OneSync, FiveM’s modern entity synchronization system. It’s required for more than 48 players (up to 2048 slots) and expected by virtually all modern frameworks and scripts. Leave it on unless a legacy resource explicitly requires otherwise.

Enforced Game Build

sv_enforceGameBuild locks the server (and connecting clients) to a specific GTA V DLC build — for example 2802 (The Criminal Enterprises), 2944 (San Andreas Mercenaries), or 3095 (The Chop Shop). Newer builds unlock newer vehicles, weapons, and map content, but every resource that references DLC content must support the build you pick.

Script Hook

sv_scriptHookAllowed 0 blocks clients from using ScriptHookV-based single-player mod menus on your server. Keep this at 0 — allowing it opens the door to client-side cheating.

Resource Start Order

Each ensure resource_name line starts a resource at boot. Resources start top to bottom, so dependencies (framework core, database connector) must appear before the scripts that use them. See Install Resources for details.

Permissions Preview

add_ace and add_principal lines define admin permissions using FiveM’s ACE system — for example granting group.admin access to commands and assigning players to that group by identifier. This is covered fully in the Add Admins guide.

Applying Changes

Changes to server.cfg take effect only after a server restart. Save the file, then restart from the Game Panel or from txAdmin.

Common Mistakes

Nothing breaks, but nothing happens either — the file is read once at startup. Always restart after saving. Some hosting setups also regenerate or cache configs, so verify your change survived the restart by checking the file again.
The most common startup failure. The console will show an authentication error and the server stops or stays unlisted. Re-copy the key from the Keymaster with no extra spaces or quotes, and make sure it isn’t already in use on another server.
If scripts error with “attempt to index a nil value” or can’t find framework exports, a dependency probably starts too late. Move framework and database resources (e.g. oxmysql, es_extended, qb-core) above everything that depends on them.
Recipes sometimes leave duplicate lines behind. If a setting doesn’t seem to apply, search the whole file — the last occurrence usually wins.

Next Steps

Install Resources

Add scripts, MLOs, and vehicles with the correct load order.

Add Admins

Full guide to ACE permissions and txAdmin admins.

Need more headroom for your city?

FiveM hosting from €4.80/month on Ryzen 7950X3D/9950X hardware — upgrade any time and keep all your files.