Skip to main content
TRACK A·INSTALL YOUR SERVER·Verified June 2026 · Lua 5.4 · ox_lib 3.x
Learning with an AI assistant?
Copies this lesson plus 2026 ground rules (no lua54 'yes', Cfx.re Portal, correct callback signatures) as a ready-to-paste mentor prompt.
Step 03

Install your first server with txAdmin

An artifact is the FXServer build you download. It is the server program. txAdmin is the browser dashboard that ships inside that build and opens by itself the first time you run it. A recipe is a one-click starter that downloads a framework and writes your first server.cfg. You do all of this with the files Cfx.re gives you. Nothing extra to install. If you would rather skip txAdmin and a database entirely for your very first test, jump to the minimal path near the end of this lesson.

You'll do
Download the recommended FXServer artifact, open txAdmin in your browser, claim it with your Cfx.re account, run a framework recipe (QBCore or ESX Legacy), check the database in HeidiSQL, and join the running server. A minimal no-framework path is included for a bare-bones first test.
Time
~25 minutes for the recipe path. Recipe downloads can be slow. The minimal path takes ~20 minutes.
You need
Step 02 done: MariaDB and HeidiSQL installed, and a free Cfx.re license key stored in your password manager.
Result
A running FiveM server you can join with connect 127.0.0.1:30120.
BEFORE YOU START

Watch the full install

The full install-and-configure walkthrough. Follow along here as you work through the steps below.

Full server install and configuration walkthrough.

This is the path most owners want: txAdmin downloads a framework for you and writes server.cfg automatically. Use QBCore or ESX Legacy. Prefer a bare server with no framework and no database first? Skip ahead to the minimal path below, then come back here when you are ready for a framework.

Download the recommended artifact

server.7z is downloaded from the recommended build.

Open the official Cfx.re Windows artifacts page.

text
https://runtime.fivem.net/artifacts/fivem/build_server_windows/master/

Download the recommended build. It is the highlighted green row on the page. That is your default choice. The newest build sits at the very top of the list, but pick that one only when you need a brand-new fix that has just landed, since it is less tested. Click the recommended build, then download its server.7z.

One rule for later: if a build ever misbehaves after an update, drop one build down. That is the only reason to ever run an older one. You do not pin or freeze anything yet. That comes once your server is live and public.

Only download from this Cfx.re page. Do not use Discord mirrors, YouTube links, or random upload sites.

Extract and run FXServer

txAdmin opens by itself at http://localhost:40120.

Make a clean folder, extract the archive into it, and run the server binary.

text
C:\FXServer\server\        <- extract server.7z here

txAdmin stores its server data (your config and resources) in C:\FXServer\txData by default, and it creates that folder for you during setup. You do not make it yourself.

Double-click C:\FXServer\server\FXServer.exe. A black console window opens and starts txAdmin. Allow the Windows Firewall prompt if it appears, then wait for your browser to open the dashboard.

text
http://localhost:40120

Keep the black FXServer console open the whole time. Closing it stops txAdmin.

The PIN is a random 4-digit code generated fresh on each first boot. It expires after roughly 15 minutes, so finish setup promptly; restart FXServer.exe for a fresh one. The number 0427 above is only an example. Type the exact digits YOUR console prints, not these. If you need a fresh PIN (for example the PIN expired, or you restarted before finishing setup), close and reopen FXServer.exe and it generates a new one.

Claim txAdmin with your Cfx.re account

txAdmin is linked to your Cfx.re identity and a local admin login exists.

On the txAdmin setup screen, enter the PIN printed in the console, then link your Cfx.re account (the same account you used to get the license key at the portal). Authorize txAdmin, set a local txAdmin password, and name your server profile.

This course describes txAdmin v8 (mid-2026); labels shift between versions, so match the intent, not the exact text. Two logins exist and they are not the same thing:

  • Cfx.re account is your global identity at portal.cfx.re.
  • txAdmin password logs you into this dashboard only.

Security: set a long, unique txAdmin password. The txAdmin dashboard on port 40120 controls your whole server, so never expose port 40120 to the open internet. On your own PC it stays on localhost. On a VPS, leave 40120 closed in the firewall and reach it over an SSH tunnel or VPN, not a public port.

Run a framework recipe

txAdmin downloads a framework and writes your first server.cfg.

When txAdmin asks how to set up the server, use the Server Deployer and pick one of its recipe templates. The deployer's built-in recipe list is CFX Default, QBCore Framework, and ESX Legacy. For a new 2026 server:

  • The easiest guided path is the QBCore recipe or ESX Legacy for the biggest script catalog and the most copy-paste tutorials.
  • Qbox is an ox-based QBCore fork for later. It is a maintained recipe but is not in the built-in list, so you install it via its remote recipe URL (the advanced manual path).

Either way, read the official framework docs and check the compatibility list for the scripts you plan to install.

The deployer then asks for the database connection and your license key. Enter the database fields from the tools lesson: host 127.0.0.1, port 3306, username root, and the MariaDB root password you set earlier. The database name you type is the one the recipe creates before it imports tables (use fivem if you have no preference, or qbcore if you are running the QBCore recipe). Then paste the key from your password manager into the key field. (Haven't created a key yet? Go to portal.cfx.re, open Servers, then the registration keys page, click Generate Key +, enter a display name, click Generate, and copy the cfxk_ value it gives you.) You do not edit any file by hand here. txAdmin writes the key into server.cfg for you as the line below. Let every recipe step finish, then click Save & Run Server.

text
sv_licenseKey "cfxk_yourkeyhere"

Exact wording varies by txAdmin build (illustrative). What matters: the recipe shows a progress list that finishes without a red error, and txAdmin then offers to start the server.

Choose the game build, then start the server

The server boots with an intentional GTA content build.

The artifact build from Step 1 is the FXServer software version. sv_enforceGameBuild is a different number: the GTA V content build clients must load. If you omit it, the server serves the base build 1604 (vanilla GTA V content); it does not auto-detect the latest. The artifact download page does not tell you which game-build number to use. Edit it in txAdmin's sidebar CFG Editor page. Keep the value written by your recipe. Change it only when a resource or map needs a newer build, and check the supported game-build list in the Cfx.re server-command reference linked below (newest supported as of mid-2026 is 3751).

text
sv_enforceGameBuild <supported_game_build>   # use the Cfx.re game-build list, not the artifact number

Save the file, then use txAdmin's Restart Server action. sv_enforceGameBuild is startup-only, so changing it requires a full server restart; restart without a resource name is not the server-restart command.

Wording is illustrative and varies by build. Success signs to look for: a line confirming license-key authentication, no repeating red errors, and the server reaching an online/listening state.

Check your database in HeidiSQL

You can browse the framework's tables in HeidiSQL.

HeidiSQL is the free GUI from Step 02 that lets you look inside the database. Open it, click New session, and fill in:

  • Host: 127.0.0.1
  • User: root
  • Password: the root password you set when installing MariaDB
  • Port: 3306

Click Open. Look for the database named what you typed in the deployer (for example qbcore or fivem); inside it you will find tables like players.

The recipe creates the database with the default charset. ESX declares utf8mb4 in its own schema; QBCore does not, which is fine for a first server.

Connect from your FiveM client

Your client joins and txAdmin shows one player online.

Open the FiveM client (the game launcher, not the black FXServer window). While FiveM is in focus, press F8 on your keyboard to open the in-game client console, then type this command and press Enter to connect to your own machine:

text
connect 127.0.0.1:30120

If the server is on a VPS instead, use its public address and the same port:

text
connect YOUR_SERVER_IP:30120

Once you spawn in, go back to txAdmin. The Players panel shows 1 online and the Live Console logs your connection. That is your proof: the server runs, and you are on it.

txAdmin writes its own data under txData/. On most installs the per-server logs sit here:

text
txData/<your-server>/logs/admin
txData/<your-server>/logs/fxserver
txData/<your-server>/logs/server

The path can move between builds. If you do not see txData, search your FXServer folder for txData and look for the logs folder inside the server profile.

How the pieces fit together

FXServer is the server software. txAdmin is the dashboard bundled inside it. A recipe is a one-click installer that downloads a framework and writes server.cfg. MariaDB stores player data. HeidiSQL is just a window into that database.

Two things are easy to confuse. Port 40120 is the txAdmin dashboard in your browser. Port 30120 is the game server your FiveM client connects to. They are different ports for different jobs. Your license key gets pasted into server.cfg for you as sv_licenseKey by txAdmin during the recipe step. You never hand-edit that file to get started with a framework.

Build it: the minimal path (no txAdmin, no framework)

You do not need XAMPP, a framework, or a database for a bare first server. This alternate path is five steps: use the artifact you already downloaded above (or download it fresh), get a license key, write a minimal server.cfg by hand, start the server, and join it. Everything else (QBCore, ESX, resources, SQL) is the recipe path above, done whenever you are ready for it.

Add the base resources and write server.cfg by hand

A server-data folder with the base resources and a minimal server.cfg.

A raw artifact cannot spawn you into the world on its own. It needs a small set of base resources (chat, the spawn manager, the session manager, the map manager, and a couple of housekeeping resources) to put you in Los Santos. These do NOT ship inside the artifact. They live in a separate Cfx.re repository called cfx-server-data, and the vanilla setup clones it. (When you use txAdmin recipes above, they include these for you, which is why you never see this step there.)

Create the data folder next to your artifact:

text
C:\FXServer\server-data\

Now put cfx-server-data inside it. Either way works:

  • With git: open Command Prompt in C:\FXServer\server-data\ and run git clone https://github.com/citizenfx/cfx-server-data.git . (the trailing dot clones into the current folder).
  • Without git: open https://github.com/citizenfx/cfx-server-data, click Code, choose Download ZIP, and extract its contents into server-data\ so you see a resources folder directly inside it.

Then create server.cfg inside C:\FXServer\server-data\ with this minimal config:

text
# How players reach your server
endpoint_add_tcp "0.0.0.0:30120"
endpoint_add_udp "0.0.0.0:30120"
 
# Your license key from portal.cfx.re (paste the cfxk_ value, no prefix)
sv_licenseKey "cfxk_your_key_here"
 
# What players see in the server name
sv_hostname "My First FiveM Server"
 
# Base resources from cfx-server-data - vanilla needs these to spawn you in
ensure mapmanager
ensure chat
ensure spawnmanager
ensure sessionmanager
ensure hardcap
ensure rconlog
 
# OneSync: not on by default - this line enables it
set onesync on
 
# Maximum players (values 32 and up require OneSync)
sv_maxclients 32

OneSync is the networking layer that lets a FiveM server hold more players and sync more entities. It is NOT on by default: set onesync on is the modern standard every server should set. Without OneSync a server caps at 31 slots; onesync legacy reaches 64 in a compatibility mode that is not recommended; set onesync on reaches up to 2048. Any sv_maxclients of 32 or more requires set onesync on (or legacy), which is why the line above is 32 with OneSync on.

That's the whole file. You don't need tags, Discord links, sv_enforceGameBuild, or extra resources yet.

Start the server

The server console shows it's running.

Do NOT double-click FXServer.exe. Launching the exe with no arguments starts the txAdmin setup wizard instead (the recipe path above). For this minimal server you point the exe at your server.cfg by hand.

Open Command Prompt, change into your data folder, and run the exe with +exec:

text
cd C:\FXServer\server-data
C:\FXServer\server\FXServer.exe +exec server.cfg

+exec server.cfg tells the server to read the config you just wrote. The console will validate the license key, load the base resources, and then settle. Watch it until it stops scrolling and prints its ready/started lines. How long that takes varies by machine.

Join your server

You're standing in Los Santos on your own server.

Open the FiveM client. Press F8 to open the in-game console (the command box built into the FiveM client). Type:

text
connect 127.0.0.1:30120

127.0.0.1 is your own PC. If you want friends on your local network to join, use your PC's local IP instead:

text
connect 192.168.x.x:30120

Find your local IP with ipconfig in Command Prompt.

A fresh local server is not something friends across the internet can reach. Internet play needs port forwarding and extra config, which is a later lesson. For now you reach your own server directly with the connect command above.

Next steps from the minimal path

Your minimal server runs but it's empty: no resources, no scripts, no framework. From here:

  • Understand your server.cfg -> see server.cfg, annotated line by line
  • Organize your folders -> see Organize your server folders
  • Add QBCore or ESX -> run the recipe path above whenever you're ready
  • Add your first resource -> see Create a basic FiveM script
  • Let friends join over the internet -> port forward 30120 on your router, give them your public IP
  • Secure it -> see the server hardening lesson

If something went wrong

SymptomFix
FXServer.exe opens then closes instantlyUsually a missing Visual C++ runtime. Install VC_redist.x64.exe from Microsoft, then run FXServer.exe again. Also allow it through Windows Firewall.
The browser never opens / localhost:40120 refusedFXServer.exe is not running or the console was closed. Reopen FXServer.exe, keep the black window open, then visit http://localhost:40120 manually.
A browser window opened asking for a PIN when I wanted the minimal pathDouble-clicking FXServer.exe always starts the txAdmin wizard. Close that window and its console, then launch with the +exec command from the minimal-path section instead.
Server license key authentication failedOpen portal.cfx.re, confirm the key is active and belongs to the account used for this server, paste the exact value into sv_licenseKey with no prefix in front of it, and restart.
The recipe download stalls or fails partwayUsually GitHub rate-limiting or slow internet. Wait a few minutes and run the recipe again. If it keeps failing, install the framework manually from its docs.
Could not connect to database / oxmysql failedStart the MariaDB service (services.msc, or Get-Service MariaDB* in PowerShell), confirm the database name matches the recipe, and check the mysql_connection_string convar host, user, and password.
MariaDB service won't start (port 3306 in use)Another MySQL is using port 3306. Stop the conflicting service, or change MariaDB's port in my.ini (at C:\Program Files\MariaDB <version>\data\my.ini) and update HeidiSQL to match.
ensure not found in the HeidiSQL consoleHeidiSQL only runs SQL, not FiveM commands. ensure is the FiveM command that starts a resource. Use the txAdmin Live Console for FiveM commands, HeidiSQL for SQL only.
Client kicked: game build mismatchCheck the value against the supported game-build list in the Cfx.re server-command reference and the requirements of your assets, then perform a full server restart. Do not use the FXServer artifact number here.
The txAdmin setup screen does not match these stepsLabels move between builds. Follow the stable task order: enter PIN, claim with Cfx.re, choose recipe, paste key, set database, Save & Run. If lost, open the txAdmin setup docs in References.
connect 127.0.0.1:30120 does nothing (minimal path)The FiveM client is not running, or the server has not finished starting yet. Wait until the console settles and shows the server is ready, then try the connect command again.
Port 40120 already in useAnother FXServer or txAdmin is already running and holding that port. Close the other console window (or restart your PC), then try again.
My server is not in the FiveM browser listExpected. A fresh local server is not listed publicly. Reach it directly with connect 127.0.0.1:30120. Public listing comes later with port forwarding.

What you can do now

  • Download the recommended FXServer artifact (the highlighted green row); use the newest top build only when you need a brand-new fix.
  • Run FXServer.exe and let the bundled txAdmin open itself at http://localhost:40120.
  • Claim txAdmin with your Cfx.re account and set a separate local dashboard password.
  • Run a QBCore or ESX Legacy recipe with your free license key to write the first server.cfg.
  • Connect HeidiSQL to the recipe's database and browse its tables.
  • Set a current sv_enforceGameBuild and join your own server with connect 127.0.0.1:30120.
  • Find txAdmin logs under txData/&lt;server&gt;/logs and search for the folder if the path moved.
  • Or skip the framework entirely: clone cfx-server-data, hand-write a minimal server.cfg, and launch with FXServer.exe +exec server.cfg.

Try it yourself