Skip to main content
TRACK B·FRAMEWORK INTEGRATION·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.
QBCore

QBCore: how the framework works

A framework is the foundation your roleplay scripts sit on. QBCore is one of the most popular FiveM frameworks. It tracks who is logged in, their money, their job, their items, and more. The resource that does this is called qb-core. Everything else (qb-inventory, qb-policejob) is a separate script that depends on qb-core and asks it for help. This lesson is about qb-core itself, not the scripts built on top of it.

You'll learn
What QBCore is, the client/server split, the Core object, PlayerData, the server and client functions you call every day, built-in and custom commands, callbacks, and a full mini script that ties it together.
Time
~20 minutes to read. Longer if you type the examples.
You need
A running FiveM server with the qb-core resource installed, and a code editor.
Result
You can read and write basic QBCore scripts and know which side each line belongs on.
BEFORE YOU START

What is QBCore?

QBCore is a framework for FiveM, which means GTA V roleplay servers. Think of it as the engine underneath all of your roleplay scripts.

QBCore itself handles these things:

  • Players. Who is logged in, their character, money, job, and gang.
  • Jobs and gangs. Police, mechanic, mafia, and so on.
  • Money. Cash, bank, and dirty money (crypto).
  • Commands. The lines you type in chat, like /job or /car.
  • Metadata. Extra data about a player, like hunger, thirst, and stress.

Other scripts build on top of QBCore. A gas-station script or a car dealership asks qb-core questions like "Who is this player? How much money do they have? Take 500 from the bank." The framework answers and does the work.

The resource is named qb-core. Every other qb- script is separate and depends on it.

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
  • The client and server split
  • The Core object
  • PlayerData
  • Server functions
  • Client functions
  • Built-in commands
  • Make your own commands
  • Callbacks
  • A complete mini example
  • Common mistakes
  • What you can do now
  • Try it yourself

The remainder of QBCore: how the framework works is available to FiveM School members.