NEW 📢 Save up to 30% on your first month, limited time offer!

How to change your FiveM server name, slots and licence key

FiveMUpdated Sep 24, 20263 min read

A FiveM server is configured almost entirely from server.cfg in the root of your server files.


1. Open the file

  1. Stop the server in the Game Panel.
  2. Open the Files tab and click server.cfg.

2. The lines you will change

LineWhat it does
sv_hostnameThe name in the server list.
sv_maxclientsPlayer slots.
sv_licenseKeyYour FiveM licence key. The server will not run without one.
sets tagsLabels shown in the server list.
sets localeThe flag shown next to your server.
set steam_webApiKeyNeeded by scripts that identify players by Steam.
endpoint_add_tcp and endpoint_add_udpThe listen address. Already set to your allocation, so leave them alone.

3. Get a licence key

  1. Go to the FiveM keymaster site and sign in with your own Cfx.re account.
  2. Create a key. When it asks for an IP, use the IP shown for your service in the panel.
  3. Paste it into sv_licenseKey in server.cfg.

The key belongs to your account. Do not share it, and do not run two servers on the same key at once.


4. Starting resources

  • Resources live in the resources folder and are started by a line in server.cfg.
  • Use ensure resourcename, which starts the resource and restarts it cleanly if it is already running.
  • Order matters. Frameworks and shared libraries go before the scripts that depend on them.

5. Save and restart

  1. Save the file.
  2. Start the server and read the console. Each resource is reported as it starts, and an error names the resource that failed.

If the server starts but nobody can join, check the console for the licence key line first. See the troubleshooting guide in this category.

CREATE YOUR GAME SERVER
READY TO GET STARTED?

Save up to 30% on your new game server.
Premium performance, instant activation, and unbeatable reliability all at a better price.

OUR LATEST BLOGS