Every FiveM server needs a licence key. It is free and you get it with your Cfx.re account. If you have read old guides mentioning Keymaster (keymaster.fivem.net): it has been retired and everything now lives in the Cfx.re Portal.
Creating the key
- Go to
https://portal.cfx.reand log in with your Cfx.re account (the same as the forum and FiveM). - Go to Servers → Registration Keys (
portal.cfx.re/servers/registration-keys) and click Generate Key +. - It only asks for a name to recognise the server. You no longer enter its IP.
- Click Generate and copy the key. It looks like
cfxk_followed by letters and numbers.
If you already had keys in Keymaster, they are in the Portal when you log in with the same account.
Where it goes
- With txAdmin: it asks for it when deploying the recipe. To change it later, edit the line in your
server.cfg(txAdmin has an editor under CFG Editor) and restart the server. - By hand in
server.cfg:
sv_licenseKey "cfxk_YOUR_KEY"
Since it is no longer tied to an IP
If you move VPS or change IP, you do not need a new one: copy the same key to the new server. But treat it like a password: do not publish it on GitHub or share it.
If the console complains about the key
- Check it is complete, with no spaces before or after, and in quotes.
- Check in the Portal that it is still active; if you deleted or regenerated it (Regenerate button), the old one stops working. Regenerating is exactly what to do if it has leaked.
- With a bad key the server may start but not appear in the public list. More causes in my server does not show up.