X
X
X
X
All systems operational · 200 Tbps+ DDoS protection active
Sign Up Sign In 08505574494

How to Set Up a FiveM Server? Step-by-Step Guide

HomepageArticlesFiveM ServerHow to Set Up a FiveM Server? Step-...
How to Set Up a FiveM Server? Step-by-Step Guide (2026)

Setting up a FiveM server means running GTA V multiplayer by your own rules. The good news: as of 2026 the process is far simpler than it used to be, because FXServer now ships with the txAdmin panel and you can get a working server online from a web interface in a few clicks. The bad news: easy setup does not mean the server will run well. The wrong hardware, an incomplete port configuration or a bad framework choice can turn into an empty server a week after launch. This guide covers the installation step by step, and also the part most guides skip — the decisions that keep a server alive and smooth.

Before You Start: What You Need

Three things must be in place before installation:

  • A Cfx.re account and a free license key. You get the key from portal.cfx.re. It is free and required for your server to appear in the server list. The key is tied to your server's IP address; if the IP changes, you must update the key.
  • A server. You can test on your own machine, but if you plan to accept outside players you need a VDS or dedicated server with a static IP. Hosting from a home connection means port forwarding headaches and insufficient upload bandwidth.
  • Open ports. FiveM uses a single port for both TCP and UDP traffic: 30120. The txAdmin panel additionally needs port 40120 to be reachable.

You only need a legitimate copy of GTA V to play; the machine hosting the server does not need the game installed.

Hardware: What Do You Need per Player Count?

Contrary to popular belief, performance in FiveM is driven not by player count but by the number and quality of running scripts (resources). A plain 64-slot freeroam server can consume fewer resources than a 32-slot heavily scripted roleplay server. Still, as a starting point:

Small server — 8-16 players

  • CPU: 4 cores, 3.5 GHz+ (single-core performance matters)
  • RAM: 4-8 GB
  • Disk: 15-20 GB NVMe SSD

Mid-size roleplay — 16-32 players

  • CPU: 6-8 cores, 3.8 GHz+
  • RAM: 12-16 GB
  • Disk: 30-40 GB NVMe SSD

Large / heavily modded — 32-64+ players

  • CPU: 8-12 cores, 4.0 GHz+
  • RAM: 24 GB and above
  • Disk: 50-100 GB NVMe SSD

Key point: the FiveM main server loop runs largely on a single core. That is why an 8-core CPU at 4.2 GHz almost always beats a 16-core at 2.4 GHz. High clock speed AMD Ryzen processors are preferred in game hosting for exactly this reason. We covered the same logic on the MTA side in our guide on how much RAM an MTA server needs.

NVMe is recommended because it noticeably shortens server boot and resource loading times compared to SATA SSDs.

Step by Step: Installation with txAdmin (Windows)

This is the fastest route. FXServer 2524 and later ships with txAdmin, so nothing extra needs to be installed.

1. Download the server files

From FiveM's official server download page, get the recommended build for Windows. The file comes as server.7z; you need 7-Zip or WinRAR to extract it. Extract to a folder such as C:\FXServer\server.

A common mistake here: choose recommended, not latest. The newest build is occasionally unstable and causes script incompatibilities.

2. Run FXServer.exe

Double-click it. A console opens and the txAdmin interface launches in your browser at http://localhost:40120. On a remote server, go to http://SERVER_IP:40120.

3. Link your Cfx account

A PIN appears on screen. Click "Link Account", sign in with your Cfx.re account and approve the authorization. Then set an admin password for the panel — this password grants full control of your server, so make it strong.

4. Name your server

This is the name players see in the server list. It can be changed later, so do not overthink it now.

5. Choose a recipe

Under "Popular Recipes" pick CFX Default FiveM. This is a clean start with no framework. You can also find ESX or QBCore recipes here — but we recommend starting clean and installing the framework afterwards; debugging is far easier that way.

6. Enter your license key

The Recipe Deployer will ask for sv_licenseKey. Paste the key you obtained from portal.cfx.re.

7. Click "Save & Run Server"

The server comes up. You can now connect from the FiveM client by opening the F8 console and typing connect SERVER_IP:30120.

Installation on Linux (Ubuntu / Debian)

For production, Linux uses fewer resources and is more stable. The steps:

Install dependencies:

sudo apt update && sudo apt install -y git xz-utils

Download the server files:

mkdir -p ~/FXServer/server && cd ~/FXServer/server
wget
tar xf fx.tar.xz

Clone the server data:

cd ~/FXServer && git clone https://github.com/citizenfx/cfx-server-data.git server-data

Start the server:

cd ~/FXServer/server-data && bash ~/FXServer/server/run.sh +exec server.cfg

txAdmin runs on port 40120 on Linux as well; on first run, paste the link printed in the console into your browser.

server.cfg: The Lines You Must Know

This file is the heart of your server. You can edit it from the panel. The critical lines:

  • endpoint_add_tcp "0.0.0.0:30120" and endpoint_add_udp "0.0.0.0:30120" — the address and port the server listens on. Both are required.
  • sv_licenseKey "your-key" — the license key. If it is wrong the server still starts, but never appears in the list.
  • sv_maxclients 48 — maximum player count. Do not set more than your hardware can handle.
  • sv_hostname "Your Server Name" — the name shown in the list.
  • ensure resource_name — one line per script. Order matters: the framework must load before anything that depends on it.
  • add_principal identifier.fivem:1 group.admin — to grant yourself admin rights.

If a script is not working, the first thing to check is whether its ensure line exists and is in the right order. The second is the error output in the F8 console.

Which Framework? ESX, QBCore and Qbox

If you are building a roleplay server you need a framework. This decision is effectively irreversible, because every script you use is written for the framework you pick.

  • ESX (Legacy): the largest script library and the widest pool of community resources. Simple structure, easy to learn. The most sensible choice for beginners.
  • QBCore: long the roleplay standard, still with a large catalogue of ready-made scripts. However, development has slowed markedly and the community has largely moved to Qbox.
  • Qbox: the modern continuation of QBCore. It integrates with the ox ecosystem and consumes noticeably less CPU than QBCore depending on load. The learning curve is steeper, but for teams with technical capacity it is the healthiest choice in 2026.

In short: ESX if this is your first server, Qbox if you have a technical team and are thinking long term.

Keeping the Server Up 24/7

Finishing the installation is not the end. To keep your server running without interruption:

  • Automatic restarts: use txAdmin's scheduled restart feature. One or two planned restarts a day prevent memory leaks from accumulating.
  • systemd service on Linux: define FXServer as a systemd service so it comes back automatically after a crash or a reboot.
  • Backups: back up your server-data folder and database regularly. It is the fastest way to recover from a broken script.
  • DDoS protection: game servers are a primary target, and because FiveM uses UDP, standard CDN solutions do not help. We covered this in detail in does Cloudflare protect a game server?
  • Server hardening: if you have just provisioned a new VDS, see our guide on the first 10 steps for server security.

Common Problems and Fixes

  • Server not showing in the list: almost always a license key issue. Verify the key is correct and registered to the server's IP address.
  • Players cannot connect: check that port 30120 is open for both TCP and UDP in the firewall. If you can open http://SERVER_IP:30120/info.json from outside, the port is fine.
  • Cannot reach the txAdmin panel: port 40120 may be blocked. Alternatively, change it with +set txAdminPort 40121.
  • Script will not load: the ensure line may be missing, or the folder name may not match the name declared in fxmanifest.lua.
  • Server stuttering / low TPS: run resmon in the console to find which script is consuming resources. Usually a single badly written script slows down the entire server.

FiveM Servers with Nubitro

A FiveM server's performance depends directly on the hardware underneath it. High clock speed, NVMe storage and the right location for low ping — without these three, even the best configuration falls short. Nubitro's FiveM server packages come with instant setup, 200 Tbps+ DDoS protection and 24/7 support. If you want more control, take a look at our AMD Ryzen 9 based VDS options in Turkey.

Frequently Asked Questions

Does it cost money to run a FiveM server?

The server software and the license key are free. The only thing you pay for is the hardware hosting it. Players also need a legitimate copy of GTA V to connect.

Can I host a FiveM server on my own computer?

For testing, yes. But to accept outside players you need port forwarding, a static IP and enough upload bandwidth — at least 20 Mbps for 16 players. For a permanent server, a VDS makes far more sense.

How much RAM do I need per player count?

Roughly: 8 GB for 16 players, 16 GB for 32, 24 GB or more for 64. But the real driver is the number of loaded scripts, not the player count. Heavy roleplay scripts can double these figures.

I forgot my txAdmin password, what now?

Run txaAdmin-resetPassword in the server console to reset it. Without console access you will need to edit the admin file in the txData folder of your server files.

Should I choose ESX or QBCore?

ESX if it is your first server — ready-made scripts are far easier to find. Since QBCore development has slowed, if you have a technical team we suggest looking at Qbox directly instead of QBCore.

How do I reduce my server's ping?

Location is the biggest factor: if your players are in Turkey, your server should be too. Script optimization comes next. For a detailed worked example of the same logic, see our ping reduction guide.

Summary

  • Installation with txAdmin takes under 15 minutes; the hard part is not the setup but everything after it.
  • Get your license key from portal.cfx.re and use the recommended build.
  • Open port 30120 for both TCP and UDP, and 40120 for the panel.
  • What drives performance is not core count but single-core speed and NVMe storage.
  • The framework decision is permanent: ESX for beginners, Qbox for technical teams.
  • Without scheduled restarts, regular backups and real DDoS protection, a server will not last.
Powered by WISECP
💬
Top