SimplisticNode

Setting up your FiveM server

Get your FiveM server live with txAdmin: how much RAM you need, your Cfx.re license key, ESX vs QBCore, MySQL, server.cfg and adding resources.

Game Servers7 min read

Every FiveM server comes with txAdmin pre-installed. txAdmin is the official web panel for running a FiveM server, and its setup wizard does most of the hard work for you. This guide takes you from a fresh server to players in your city, and covers sizing, frameworks, resources and the most common problems.

What you need before you start

  • A FiveM server with us, and your login for our game panel.
  • A Cfx.re account, which you use to sign into the FiveM forums and portal.
  • A free server license key from Cfx.re (step 1 below).
  • An idea of which framework you want. More on that below.

How much RAM does a FiveM server need?

FiveM leans heavily on single-thread CPU speed, which is why every plan runs on high-clock Ryzen CPUs. RAM then decides how many resources, vehicles and players you can run comfortably. As a guide:

  • 2 GB (Starter): a new roleplay community finding its feet, or a small standalone server.
  • 4 GB (Roleplay): an active roleplay server running a full framework.
  • 6 GB (City): the go-to size for a busy roleplay city.
  • 8 GB (Metropolis): a large, established roleplay server.
  • 12 GB and above (Megacity through to Titan): heavy frameworks, big player counts, large networks and busy event days.

Custom vehicles, clothing and MLO interiors add up quickly, so if you plan to stream a lot of custom content, size up. You can upgrade at any time.

1. Get a license key

Every FiveM server needs a free server license key from Cfx.re, the team behind FiveM.

  1. Sign into the Cfx.re portal (portal.cfx.re) with your Cfx.re forum account.
  2. Go to the server license keys section and register a new key.
  3. Give it a name, choose your server's details when asked, and create it.
  4. Copy the key somewhere safe. Treat it like a password and never share it publicly.

2. Create a MySQL database

ESX, QBCore and most roleplay resources store players, jobs and inventories in MySQL. Open the Databases tab for your server in our game panel and create a database. Free MySQL databases are included with every plan. Keep the host, port, database name, username and password handy for the next step.

3. Run the txAdmin setup

  1. Start your server in our game panel and watch the console. txAdmin prints its web address and a one-time PIN.
  2. Open that address in your browser, enter the PIN, and link your Cfx.re account to create your admin login.
  3. Give your server a name, then choose a deployment type. Popular Recipes installs a ready-made framework for you.
  4. Pick your recipe, paste in your license key when asked, and enter your MySQL details from step 2.
  5. Let the recipe run. It downloads the framework, creates the database tables and writes your server.cfg.
  6. When it finishes, start the server from txAdmin. The live console will show resources starting up.

ESX, QBCore or vRP: which framework should I use?

  • QBCore: a modern, very popular roleplay framework with a big library of compatible jobs and scripts. There is a txAdmin recipe for it.
  • ESX (ESX Legacy): the long-standing roleplay framework, with years of community resources. There is a txAdmin recipe for it too.
  • vRP: an older framework that some communities still prefer. It is usually installed by hand rather than from a recipe, so choose a blank or local server data option and upload your own files.
  • Standalone: no framework at all, which suits race, drift or freeroam servers.

Pick one and stick with it. Scripts are generally written for a specific framework, and switching later means rebuilding a lot of your server. If you are buying paid scripts, check they support your framework before you pay.

4. Key server.cfg settings

The recipe writes a working server.cfg for you, but these are the lines you will most likely want to change. You can edit the file from txAdmin or the file manager in our game panel.

  • sv_hostname: the name shown in the server browser.
  • sets sv_projectName and sets sv_projectDesc: your server's title and a short description.
  • sv_maxclients: the maximum number of players at once.
  • sv_licenseKey: your Cfx.re license key. Keep it out of anything you share publicly.
  • set mysql_connection_string: how your MySQL resource connects to the database. The recipe fills this in for you.
  • ensure lines: the resources that start with your server, in order.

How many players can a FiveM server have?

Your slot count is set by sv_maxclients, but Cfx.re also sets limits based on your license key. Larger player counts need OneSync enabled, and going above the free slot limit needs a paid Cfx.re membership linked to your key. Limits change from time to time, so check the Cfx.re portal for the current rules before planning a big launch.

5. Add resources

  1. Upload the resource folder into your resources folder using the file manager or SFTP. Sub-folders in square brackets, such as [custom], help keep things tidy.
  2. Check the resource's instructions for any SQL file to import into your database, and any config to fill in.
  3. Add a line to server.cfg that says ensure followed by the resource's folder name, below your framework's own resources.
  4. Restart the server from txAdmin and check the console for errors.

Add resources one at a time and restart after each. If something breaks, you will know exactly which one caused it.

6. Add your staff in txAdmin

Open the Admin Manager in txAdmin to add staff members, linked to their Cfx.re or Discord accounts. Give each person only the permissions they need. From txAdmin your team can warn, kick and ban players, view player history, schedule restarts and watch the live console.

Keeping FiveM updated

FiveM's server software is called the artefact. Artefacts update automatically on our plans, and you can pin a specific version from the panel if a script needs an older build. Scheduled restarts in txAdmin, for example every 6 or 12 hours, also help keep a busy server fresh.

Letting players in

Players can find you in the FiveM server browser once you are listed, or connect directly by pressing F8 in FiveM and typing connect followed by your server's IP and port, as shown in our game panel.

Common FiveM problems and fixes

  • Invalid or missing license key: check sv_licenseKey has no extra spaces or quote marks, and that the key has not been deleted in the Cfx.re portal.
  • Could not find resource: the name after ensure must match the folder name exactly, and the folder must contain an fxmanifest.lua file rather than another folder with the same name inside it.
  • Database connection errors: check the connection string matches the database details in our game panel, and that you imported the resource's SQL file.
  • Server not in the browser: give it a few minutes after starting, and check the console for errors about your key or endpoints.
  • Players stuck loading: usually a broken or oversized streamed asset. Remove recently added vehicles or maps one at a time to find it.

Protecting your server

Every plan includes always-on DDoS protection. For cheaters, txAdmin gives you bans and player history, and our FiveGuard anticheat adds dedicated protection if your community needs it. Keep your license key, database password and txAdmin logins private, and only give admin access to people you trust.

Running a roleplay community? Our SnailyCAD hosting pairs nicely with it for dispatch and records. And if you get stuck, our team knows FiveM, so ask us on live chat or Discord.

Still stuck?

Our team is on hand 24/7. Ask on Discord for a quick reply, or open a ticket and we'll sort it.