fivemHow to Install Custom Scripts in FiveM – Complete Guide for ESX & QBCore [2026]
What Are Custom Scripts in FiveM?
Custom scripts are community-made or developer-built resources that add new features, jobs, systems, and mechanics to your FiveM roleplay server. Unlike vanilla GTA V, custom scripts let you add:- Police MDT & dispatch systems
- Drug labs, robberies & heists
- Custom job frameworks (mechanic, EMS, taxi)
- Crafting, housing & phone systems
- Admin menus & anti-cheat tools
- Economy boosters, casinos & minigames
If your MLOs are what your world looks like, custom scripts are what make it feel alive. They're the fastest way to turn a blank server into a fully functioning roleplay experience — and keep players coming back every day.
Why Install Custom Scripts on Your Server
| Benefit | Why It Matters |
|---|---|
| Gameplay depth | Scripts add mechanics vanilla GTA V simply doesn't have |
| Server identity | Unique script loadouts make your server stand out |
| Player retention | More to do = longer sessions and returning players |
| Job integration | Scripts tie directly into police, EMS, mechanic, and civilian roles |
| Community growth | Feature-rich servers get recommended — free word-of-mouth growth |
Did you know? Every script on FiveVault is made for most frameworks — ESX, QBCore, QBOX, OX Core, or Standalone — so you always know what you're installing. Browse all scripts →
Prerequisites
| Requirement | Details |
|---|---|
| FiveM server | Any artifact build, 6016+ recommended |
| Server access | SFTP (FileZilla, WinSCP) or file manager via hosting panel |
| A script resource | Downloaded from FiveVault — tagged by framework compatibility |
| server.cfg access | To add the ensure line |
| txAdmin | Recommended for easy resource management and restarts |
| Database (optional) | MariaDB / MySQL required for scripts that save player data |
Step 1: Download Your Script
Head to FiveVault and pick a script that fits your server. Always check the framework tag — ESX, QBCore, QBOX, OX Core, or Standalone — before downloading.
Once downloaded, extract the .zip or .rar. You should see a folder structured like this:
my-custom-script/
├── client/
│ └── main.lua
├── server/
│ └── main.lua
├── shared/
│ └── config.lua
└── fxmanifest.luaPro tip: If the folder contains only loose.luafiles with nofxmanifest.lua, the resource is incomplete or outdated. Always download from a trusted source like FiveVault to avoid broken scripts.
Step 2: Read the Config Before Installing
Before uploading anything, open shared/config.lua (or config.lua if it's in the root). This file controls how the script behaves on your server.
A typical config looks like this:
Config = {}
Config.Framework = 'esx' -- change to 'qb' for QBCore
Config.Locale = 'en'
Config.EnableNotifications = true
Config.MaxPlayers = 64
Config.JobName = 'police'Pro tip: Some scripts have aREADME.mdorINSTALL.mdinside the folder — always read it. It will list required dependencies likeox_lib,ox_inventory, orqb-menu.
Step 3: Import the SQL File (If Required)
Scripts that store player data — like housing, garages, job whitelists, or inventories — come with a .sql file. You must import this into your database before starting the script.
- Open your hosting control panel and navigate to phpMyAdmin
- Select your FiveM database on the left
- Click the Import tab at the top
- Upload the
.sqlfile from the script folder - Click Go — you should see a success message
SOURCE /path/to/your/script.sql;Pro tip: Always back up your database before importing a new .sql file. A bad import is much easier to recover from if you have a fresh backup.
Step 4: Upload to Your Server's Resources Folder
Connect to your server via SFTP or your hosting panel's file manager. Navigate to your resources folder:
server-data/
└── resources/Best practice is to keep scripts organised in a dedicated subfolder:
resources/
└── [scripts]/
└── my-custom-script/Upload the entire extracted script folder into resources/[scripts]/. Do not rename the folder after uploading — the name must match exactly what you put in server.cfg.
Step 5: Verify the fxmanifest.lua
Before starting your server, open fxmanifest.lua inside the script folder and confirm it looks something like this:
fx_version 'cerulean'
game 'gta5'
description 'My Custom Script'
version '1.0.0'
shared_scripts {
'@ox_lib/init.lua',
'shared/config.lua'
}
client_scripts {
'client/*.lua'
}
server_scripts {
'@oxmysql/lib/MySQL.lua',
'server/*.lua'
}
dependencies {
'ox_lib',
'oxmysql'
}If the manifest lists dependencies, you must have those resources installed and started before this script. Missing a dependency is one of the most common causes of errors.
Step 6: Add the Script to server.cfg
Open your server.cfg and add the ensure line. Place it after your framework and any dependencies it needs:
# Framework
ensure es_extended
# or
ensure qb-core
# Dependencies (always before the script)
ensure ox_lib
ensure oxmysql
# Scripts
ensure [scripts]/my-custom-scriptFor servers with many scripts, keep them grouped by category:
# Job scripts
ensure [scripts]/esx_policejob
ensure [scripts]/esx_ambulancejob
ensure [scripts]/esx_mechanicjob
# Economy scripts
ensure [scripts]/esx_banking
ensure [scripts]/esx_shops
# Utility scripts
ensure [scripts]/esx_adminmenu
ensure [scripts]/esx_notifyStep 7: Restart and Test
Restart the resource in your txAdmin console or server console:
restart [scripts]/my-custom-scriptOnce in-game, test the script's core functionality. For example:
- A job script → try clocking in at the job marker
- A shop script → try opening the shop menu
- An admin script → try running an admin command
If everything works, you're done. If not, check the troubleshooting section below.
Framework Compatibility
| Framework | Compatibility Notes |
|---|---|
| Standalone | Works on any server without framework config. Plug-and-play. |
| ESX | Scripts use exports['es_extended']:getSharedObject() or ESX events |
| QBCore | Scripts use exports['qb-core']:GetCoreObject() or QB events |
| QBOX | Same as QBCore — fully compatible with QBCore scripts in most cases |
| OX Core | Works standalone, pairs with ox_lib, ox_inventory, and ox_target |
fxmanifest.lua. If you see dependency 'es_extended' — it's ESX only. If you see dependency 'qb-core' — it's QBCore only. If you see neither — it's standalone and works on any server.
Troubleshooting Common Script Issues
❌ "Could not find resource" error in console
Solution: The folder name inserver.cfg doesn't match the actual folder name on disk. Check for typos. Linux hosting is case-sensitive — My-Script and my-script are different folders.
❌ Script starts but nothing happens in-game
Solution: Openconfig.lua and check your framework setting. If it's set to 'esx' and you're running QBCore, the script won't fire correctly. Update the config to match your framework.
❌ "attempt to index a nil value" Lua error
Solution: A dependency is missing or starting after this script. Checkfxmanifest.lua for listed dependencies and make sure they appear above your script in server.cfg.
❌ SQL-related error on server start
Solution: The.sql file was not imported or imported into the wrong database. Re-import it via phpMyAdmin and restart the resource.
❌ ESX script not working on QBCore (or vice versa)
Solution: You've installed a framework-specific script on the wrong framework. Check the FiveVault framework tag before downloading. Use the correct version, or find a bridge resource.❌ Server crashes on startup after adding the script
Solution: Thefxmanifest.lua references a missing file or dependency. Comment out the ensure line, restart cleanly, then check your console for the exact error.
❌ Config changes aren't taking effect
Solution: You must restart the resource after editing config files — saving the file alone does nothing. Runrestart [scripts]/my-custom-script in your server console.
Recommended Scripts for Your Server
| Script Name | Type | Best For |
|---|---|---|
| esx_policejob / qb-policejob | Job script | Police RP servers |
| esx_ambulancejob / qb-ambulancejob | Job script | Medical & EMS RP |
| ox_inventory | Inventory system | All frameworks |
| ox_lib | Utility library | All frameworks |
| qb-phone / qs-smartphone | Phone system | Modern RP servers |
| esx_banking / qb-banking | Economy | All RP servers |
| PolyZone / ox_zones | Zone system | All frameworks |
| esx_adminmenu / qb-adminmenu | Admin tools | All servers |
Final Tips
- ✅ Read the config first — misconfigured settings cause 90% of script issues
- ✅ Check the framework tag on FiveVault before you download anything
- ✅ Install dependencies in order — they must appear above your script in
server.cfg - ✅ Import SQL before starting — scripts that need a database will error immediately without it
- ✅ Test on a dev server first — a broken script can cause your entire server to fail to start
- ✅ Don't add 20 scripts at once — install and test in batches to isolate any issues
- ✅ Back up server.cfg before every session of adding new resources
- ✅ Use txAdmin's resource list to confirm scripts show as "started" with no errors
Frequently Asked Questions
Q: Do players need to download anything to use custom scripts?A: Client-side .lua files are streamed automatically. Players never need to manually install anything.
A: Not directly. Framework-specific scripts are written for one framework. You'll need a QBCore version of the script, or a community-made conversion.
Q: Why does my script work in the console but not in-game?A: The script may be triggering server-side events that don't reach the client. Check for client-side errors in F8 and server-side errors in your txAdmin console simultaneously.
Q: How many scripts can I run before performance drops?A: There's no hard limit, but poorly written scripts with constant loops or unoptimised database queries will cause lag. Always source scripts from trusted platforms like FiveVault.
Q: Can I edit scripts after installing them?A: Yes — most scripts are open source. You can edit .lua files directly. Always restart the resource after making changes.
A: Client scripts run on each player's machine (UI, animations, local interactions). Server scripts run on the server (database, economy, permissions). Both are needed for most full-featured resources.
Need help getting your scripts working? Join our Discord — 7,000+ members and counting.