Skip to main content
TRACK A·PLAN 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.
Track A · Step 1 · Start here

Plan your first FiveM server

Do not start by downloading 30 scripts. Start by deciding what you are building and what each part depends on. This lesson gives you the map first. Then it sends you to the detailed installation lessons in the right order.

You'll build
A one-page server plan and dependency map you can use before buying hosting or installing scripts.
Time
20-30 minutes. No installs yet.
You need
A browser and a blank file named server-plan.md.
Pass condition
Your plan names the server idea, hosting route, framework shortlist, required systems, dependencies, install order, and first test.
Verified
June 2026 against current Cfx.re, txAdmin, ESX, QBCore, Qbox, and Overextended (oxmysql) sources.
Preview of what you will do in Step 03. Watch it for the complete flow, but do not follow along yet. Use the verified chapters below for each decision and checkpoint.
BEFORE YOU START

1. Plan first or regret it later

The fastest way to waste a weekend is to install resources before you decide what the server is.

Write five things first: the promise, the hosting route, the framework shortlist, the must-have systems, and the dependency order. The plan can change later. Its job today is to stop random installs.

The map in plain English

A roleplay server is a stack of parts. Each part has one job.

PartWhat it doesTypical 2026 choice
FiveM server platformRuns FXServer, networking, resources, and player connections.Cfx.re FXServer with txAdmin
DatabaseKeeps money, characters, vehicles, jobs, and inventories after a restart.MariaDB
Database connectorLets server-side resources query the database.oxmysql
FrameworkGives resources a shared model for players, jobs, accounts, and callbacks.ESX Legacy, QBCore, or Qbox
Libraries and systemsAdd reusable menus, targeting, inventory, voice, and other shared features.ox_lib, ox_target, inventory choice, pma-voice
Gameplay resourcesAdd the actual jobs, housing, garages, phones, maps, and other features.Compatible resources you choose

The order matters. Upper layers depend on the layers below them. A garage resource cannot save a vehicle if its database tables or connector do not exist. A QBCore job resource cannot run on an ESX server unless the author explicitly supports both.

Build your server plan

Create a blank file called server-plan.md. Then complete each step below. The examples are starting points, not decisions made for you.

Write the server promise

a stranger can understand the server in one sentence.

Write who the server is for, the style of roleplay, and what players should spend most of their time doing.

code
# My FiveM server plan

## Server promise
A beginner-friendly serious-roleplay city for 32 players, built around police,
EMS, mechanic work, player-owned businesses, and a controlled economy.

Avoid vague promises such as "the best city" or "everything included." A useful promise limits the first version so you can actually test it.

Choose local or hosted

you know where the first working server will run.

Pick one route for the first setup.

ChooseUse it whenFirst proof
Local Windows PCYou are learning alone and want cheap, safe testing.FiveM connects to 127.0.0.1:30120.
Hosted server or VPSStaff or remote testers need access now.A second PC connects using the hosted address.

A VPS is a virtual private server, a rented Linux or Windows machine you control over the internet.

Add the decision and reason to your plan.

code
## Hosting route
Route: Local Windows PC
Why: I am learning alone and do not need public access yet.
Move to hosting when: two remote testers are ready.

Do not mix a Windows-local tutorial with Linux VPS paths. The concepts are the same. The folders, permissions, firewall setup, and service management differ.

Map the platform and data layers

you can name the program behind each basic server job.

Record these roles in your own words.

  • FXServer artifact: the Cfx.re server program. You install it in the next lessons. Install the recommended build (the highlighted green row) unless you specifically need a brand-new fix.
  • txAdmin: the browser control panel included with FXServer. It starts, stops, monitors, and configures the server.
  • Cfx.re Portal: the current home for creating and managing the server license key. Use https://portal.cfx.re.
  • MariaDB: the database engine that stores persistent server data.
  • HeidiSQL: a desktop database client used to inspect MariaDB and import SQL files.
  • oxmysql: a FiveM resource that lets server-side scripts query MariaDB.

Add this section.

code
## Foundation
Platform: FXServer with txAdmin
License management: Cfx.re Portal
Database: MariaDB
Database viewer: HeidiSQL
Database connector: oxmysql

Shortlist a framework

you compare compatibility instead of choosing from hype.

A framework gives resources shared concepts such as players, jobs, money, and callbacks. Use one primary framework.

  • ESX Legacy: established ecosystem and broad third-party script availability.
  • QBCore: established QB ecosystem with its own conventions and resources.
  • Qbox: a QBCore-derived framework built around the ox ecosystem. A recipe is a one-click txAdmin starter that downloads a framework and writes your first server.cfg. txAdmin's built-in recipe list is CFX Default, QBCore, and ESX Legacy only. Qbox has a maintained recipe too, but it is not built in; you deploy it from its remote recipe URL, so treat it as an advanced path for later.

There is no universal winner. Check the recipe, documentation, maintenance activity, and every must-have resource you plan to use. Do not buy an ESX-only package before choosing Qbox, and do not buy a QB-only package before choosing ESX.

code
## Framework shortlist
Candidate 1:
Candidate 2:
Must-have resources checked for compatibility:
Final choice: Not chosen until compatibility checks are complete

Separate must-have systems from later ideas

the first playable version has a controlled scope.

Make two lists.

The first list contains only what is required for a player to join and complete your server's basic roleplay loop. Everything else waits.

code
## Must have for the first playable test
- Framework and character system
- Database connector
- Inventory
- Voice
- One legal job and one emergency job
- One vehicle shop and garage path

## Add after the first test passes
- Housing
- Custom phone
- Extra jobs
- Paid maps and vehicle packs

This is scope control, not a permanent restriction. A small server that starts cleanly is useful. A huge resource folder with 200 errors is not.

Build the dependency map

each resource has an owner, source, and prerequisites before installation.

For each must-have system, record the exact resource, official source, supported framework, database needs, and dependencies.

code
## Dependency map
| System | Resource | Framework support | Needs | SQL included | Official source checked |
| --- | --- | --- | --- | --- | --- |
| Database connector | oxmysql | Framework independent | MariaDB | No | Yes |
| Shared UI/library | ox_lib | Check each resource | None | No | Yes |
| Inventory | To decide | To verify | Framework, ox_lib, oxmysql | To verify | No |
| Voice | pma-voice | Standalone | OneSync/audio config | No | No |

OneSync is the FiveM networking mode that raises the player limit above the 31-slot cap you get without it. It is not on by default, so you add set onesync on in server.cfg later.

Never assume a dependency from a folder name. Read the current README, documentation, release notes, and fxmanifest.lua for the exact version you will install.

Turn dependencies into an install order

you have a safe sequence and a test after every layer.

Install the foundation before gameplay resources. The exact names vary, but the reasoning stays stable.

code
FXServer + txAdmin
  -> database and connection string
  -> database connector
  -> framework recipe and framework dependencies
  -> shared libraries
  -> inventory, target, voice, and other core systems
  -> one gameplay resource
  -> test, back up, then add the next resource

Do not copy that diagram directly into server.cfg. Official recipes often manage multiple resources and category folders for you. The later server.cfg lesson teaches the real ensure order for the stack you install. ensure is the server.cfg command that starts a resource at boot.

code
## Install and test order
1. Start the base recipe and confirm txAdmin has no repeating errors.
2. Confirm the database connection before installing database-backed scripts.
3. Join with one clean test account.
4. Install one resource.
5. Restart that resource and check txAdmin plus F8.
6. Back up the working state before adding another resource.

F8 is the in-game client console. You open it by pressing F8 while the FiveM client is in focus, and it reports client-side script errors.

Define the first proof

you know exactly when planning is finished and setup can begin.

Finish your file with a pass condition.

code
## First proof
[ ] Hosting route chosen
[ ] Framework shortlist checked against must-have resources
[ ] Foundation tools named
[ ] Dependencies recorded from official sources
[ ] Install order written
[ ] First test defined: one player connects and creates a character
[ ] Rollback rule: back up before every new resource or update

Keep reading the full lesson

Sign in to start, then unlock every step of this lesson and the full FiveM School with a membership.

Still ahead in this lesson
  • 2. What you need before you start
  • 3. Installing server artifacts
  • 4. Setting up with txAdmin
  • 5. How it all fits together
  • 6. server.cfg walkthrough
  • 7. Keeping files organized
  • 8. Tools you will use
  • 9. MariaDB, HeidiSQL, and oxmysql
  • 10. Running SQL safely
  • 11. ESX vs QBCore vs Qbox
  • 12. Adding resources
  • 13. What is fxmanifest.lua?
  • 14. Vectors and placing things
  • 15. Script config patterns
  • 16. Tracking changes with Git
  • 17. Performance
  • 18. Security
  • 19. Debugging
  • 20. Common mistakes and next steps
  • Try it yourself

The remainder of Plan your first FiveM server is available to FiveM School members.