ITEMSTUTORIALHOW-TOOX_INVENTORYQBCOREESXQBOXINVENTORYSERVER SETUPITEM CREATOR October 25, 2026 · 13 min read

How to Add Items in FiveM (2026 Guide)

Adding items in FiveM sounds like one line in a file. It’s really four things: the item entry, the icon, what happens when someone uses it, and a restart so the inventory actually loads it. Skip one and you get the report every server owner knows. The item is there, it has no picture, and using it does nothing.

I’ve added items by hand on ox_inventory, QBCore and ESX more times than I can count, and eventually built a tool so I’d stop doing it. This guide covers how to add items in FiveM on each of them, the mistakes that quietly delete items from players, and the in-game way if you’d rather not touch the files at all.

Food and drink with a prop in the hand have extra steps of their own, covered in how to add custom food items to FiveM. Everything here applies to those too.

What It Takes to Add Items in FiveM

Four pieces, and each inventory wants them in its own place:

  1. The item entry. The name, label, weight and whether it stacks. It lives in an item file, or in the database on ESX.
  2. The icon. A PNG in the inventory’s image folder, named to match.
  3. The use. A callback in a server script that runs when the item is used. Materials and junk items can skip it.
  4. The load. Inventories read their item list when they start, so a new entry needs something restarted.

All the way through, I’ll add one item: a pair of bolt cutters. It’s a tool, so it should never get used up.

Pick a Name You’ll Never Change

The item name is what the inventory, the database and every other script call it. Use lowercase letters, numbers and underscores, and prefix it with something unique to your server. boltcutter is probably taken by some script already. ls_boltcutter isn’t.

Never rename or remove an item players already hold. When a player loads in, the inventory checks every stack against its item list and drops anything it doesn’t recognise, and the next save makes that permanent. Renaming ls_boltcutter to ls_boltcutters doesn’t rename anything. It deletes every pair on your server. If you need a new name, add it as a second item and leave the old one defined.

How to Add Items to ox_inventory (Qbox and ESX)

ox_inventory is the default on Qbox and a common choice on ESX. Current releases ship bridges for Qbox, ESX, ND Core and ox_core; QBCore is no longer one of them. If ox isn’t installed yet, start with our ox_inventory setup guide.

The Item Entry

Items live in ox_inventory/data/items.lua:

['ls_boltcutter'] = {
    label = 'Bolt Cutters',
    weight = 1500,
    stack = false,
    description = 'Cuts padlocks and chain.',
    consume = 0,
    server = {
        export = 'ls_tools.boltcutter',
    },
},

What the fields do:

  • weight is in grams.
  • stack = false gives each pair its own slot.
  • server.export hands the use to an export called boltcutter in your own ls_tools resource.
  • consume = 0 keeps the item after use. Give an item a server export and ox uses one up on every use unless you say otherwise.

The Icon

Save a square PNG as ox_inventory/web/images/ls_boltcutter.png. ox looks for <item name>.png in that folder unless the item sets client.image. If yours comes up as a blank square, fix FiveM inventory images not showing goes through every cause.

The Use

Here’s a version that looks right:

-- ls_tools/server.lua: this never runs for the bolt cutters
exports('boltcutter', function(event, item, inventory, slot, data)
    if event == 'usedItem' then
        TriggerClientEvent('ls_tools:cutLock', inventory.id)
    end
end)

It does nothing. ox only sends usedItem after it has used up a count of the item, and consume = 0 means it never does. Put tool logic under usingItem, which fires on every use:

-- ls_tools/server.lua
exports('boltcutter', function(event, item, inventory, slot, data)
    if event == 'usingItem' then
        -- return false here to refuse the use
        TriggerClientEvent('ls_tools:cutLock', inventory.id)
    end
end)

For a player’s own inventory, inventory.id is their server id. ls_tools:cutLock is your own client event that does the actual cutting.

On Qbox you can skip the export and register the use with the framework instead, the way older scripts do. Leave consume and server off the item, and ox hands the use to qbx_core. On ESX it does the same with ESX.RegisterUsableItem.

-- ls_tools/server.lua (Qbox)
exports.qbx_core:CreateUseableItem('ls_boltcutter', function(source, item)
    TriggerClientEvent('ls_tools:cutLock', source)
end)

That hand-off only happens for items with no use data of their own. Give the item a client.usetime, client.status, client.export, a server.export or a consume value, and ox runs its own use and never calls the framework.

Loading It

ox_inventory reads data/items.lua once, when it starts, and has no export to add an item while it runs. So a new item means restarting ox_inventory or the whole server. On a live server, an ox restart costs more than it looks:

  • Every open inventory closes, and ox clears ground drops and temporary stashes. It never saves them.
  • Scripts that registered shops, stashes or hooks with ox lose them until those scripts restart too.
  • Anything with a dependency on ox_inventory stops with it, and FiveM doesn’t start it again.

Run saveinv in the server console first so pending changes reach the database. Better still, add items on a dev server and let them go live at your next scheduled restart.

How to Add Items on QBCore (qb-inventory)

On QBCore, the item entry lives in qb-core, not in the inventory.

The Item Entry

In qb-core/shared/items.lua:

ls_boltcutter = { name = 'ls_boltcutter', label = 'Bolt Cutters', weight = 1500, type = 'item', image = 'ls_boltcutter.png', unique = true, useable = true, shouldClose = true, description = 'Cuts padlocks and chain.' },

weight is in grams, unique = true gives each pair its own slot, and image is the file name the inventory looks for. useable = true is required, or using the item does nothing.

The Icon

Save it as qb-inventory/html/images/ls_boltcutter.png, matching the image field exactly. ps-inventory and lj-inventory use an html/images folder in their own resource.

The Use

The classic mistake is registering the use in a client file:

-- ls_tools/client.lua: wrong side
local QBCore = exports['qb-core']:GetCoreObject()

QBCore.Functions.CreateUseableItem('ls_boltcutter', function(source, item)
    TriggerEvent('ls_tools:cutLock')
end)

CreateUseableItem only exists on the server. On the client it’s nil, so the resource throws an “attempt to call a nil value” error as it starts and the item never works. Move it to a server script:

-- ls_tools/server.lua
local QBCore = exports['qb-core']:GetCoreObject()

QBCore.Functions.CreateUseableItem('ls_boltcutter', function(source, item)
    TriggerClientEvent('ls_tools:cutLock', source)
end)

The callback gets the player’s server id and the item from their inventory, and tells that player’s client to do the work.

Loading It

qb-core reads shared/items.lua when it starts. Restarting qb-core on a live server breaks every script that grabbed its core object, so in practice a new entry in the file means a server restart. qb-core does have AddItem and AddItems exports for scripts, but what they add lives in memory and is gone at the next restart. The file entry is still the one that counts.

One more QBCore quirk: when you change an existing item, stacks players already hold keep the old label, weight and image until they relog. Stashes keep them for good.

How to Add Items on ESX

On ESX with ox_inventory, follow the ox section above. ox copies new rows from the ESX items table into its own file when it starts, but writing the ox entry directly is cleaner. The rest of this section is for the default ESX inventory.

The Item Entry

Items are rows in the items table:

INSERT INTO items (name, label, weight, rare, can_remove)
VALUES ('ls_boltcutter', 'Bolt Cutters', 2, 0, 1);

ESX counts weight in kilograms, and the stock weight column only takes whole numbers, so 1.5 kg becomes 2.

The Icon

There isn’t one. The default ESX inventory is a list without item icons, so there’s no image folder to fill. If you want icons on ESX, that’s a good reason to move to ox_inventory, and our inventory scripts comparison covers the switch.

The Use

-- ls_tools/server.lua
local ESX = exports.es_extended:getSharedObject()

ESX.RegisterUsableItem('ls_boltcutter', function(source)
    TriggerClientEvent('ls_tools:cutLock', source)
end)

ESX keeps one callback per item name, and the last one registered wins. If another resource registers the same name after yours (esx_basicneeds registers everything in its own config, for example), your callback quietly stops running.

Loading It

ESX reads the items table when it starts. On ESX 1.12 and older, a new row needs a full server restart, and restarting es_extended on its own is never the answer: it destroys every player object. ESX 1.13 and newer can add items while the server runs (ESX.AddItems, on the default inventory only), which is what in-game tools build on.

What Each Change Costs the Hard Way

What you changed What has to restart
New item, label or weight on ox_inventory ox_inventory, or the server
New item, label or weight in qb-core The server
New item on ESX 1.12 The server
New icon The inventory resource, so FiveM sends players the file
Your use callback Only your own resource

Two restarts you should never do on a live server: oxmysql and your framework. Everything that depends on them stops, and nothing starts it again. If it happens anyway, start them back framework first and inventory last.

Troubleshooting New Items

What you see What’s usually wrong
The item shows as a blank square The image is missing, misnamed or not a PNG, or the inventory hasn’t restarted since you added it
Using it does nothing (QBCore) useable isn’t true, or CreateUseableItem is in a client file
Using it does nothing (ox) Tool logic under usedItem with consume = 0, or the item has its own use data, so the framework callback never runs
Using it does nothing (ESX) Another resource registered the same item name after yours
Players lost an item after a restart It was renamed or removed from the item list
Old label or icon on existing stacks (QBCore) qb keeps them until the player relogs, and stashes keep them for good
A shop or stash vanished after restarting ox The script that registered it needs a restart too

The In-Game Way: LMX Item Creator

Full disclosure: this is our script. Everything above is the work the LMX Item Creator was built to take off your hands.

You type /itemcreator, press New item and pick a template: food, drink, drug, medical, tool, material or misc. The tool template sets Amount used to 0, which is the consume = 0 lesson from earlier done for you. Type the label and the item name is suggested from it. The name locks at the first publish, so nobody can rename an item into deleting every copy.

Then add an icon and say what using it does: the duration, the animation, the prop in the hand, who can use it, its effects and what it gives back. Test on me runs the whole use on your own character, with nothing taken and nothing published.

Then you press Publish. Before anything moves, the plan tells you what the change costs on your inventory, with the players online on screen:

  • Use behaviour, effects, shops and recipes go live on every inventory with nothing restarted.
  • A new item on qb-inventory, ps, lj or ESX 1.13+ goes live at once too. A new icon on the qb family restarts that inventory when LMX copies the file in.
  • A new item on ox_inventory restarts ox_inventory for a few seconds. The server keeps running and nobody is disconnected, but ox clears ground drops, and the plan says so first.
  • ESX 1.12, ak47_inventory and CodeM mInventory Remake need a server restart. That’s their design, and the editor tells you before you press anything.

When a restart does happen, it’s guarded: one publish at a time, files written and read back before anything restarts, inventories saved, players warned, and anything that stopped with the inventory started again. At every server start, joining players wait at the door until every published item is loaded. If loading fails, nobody gets in, so nobody loads a character holding items the server doesn’t know.

It runs on Qbox, QBCore, ESX, ND Core, ox_core or no framework at all, and the only dependency is oxmysql. There are adapters for 20 inventories, but only ox_inventory, qb-inventory (v2 and legacy) and the ESX default inventory are tested in game. The rest are built from each vendor’s docs and marked that way. Your existing items come in from 8 file formats, and everything exports back out whenever you want.

The LMX Item Creator showcase video shows items being made in game, icons, shops and crafting included.

If you’d rather weigh it against the other tools first, our item creator comparison covers them honestly, free ones included.

Adding Items in FiveM: Quick Answers

Do I have to restart the server to add an item? It depends on the inventory. ox_inventory needs ox_inventory itself restarted. File entries in qb-core and new rows on ESX 1.12 need a server restart. ESX 1.13 and newer can add items live on the default inventory.

What unit is item weight in? Grams on ox_inventory and qb-core, kilograms on ESX.

Where do item images go? ox_inventory/web/images/ on ox, qb-inventory/html/images/ on qb, and nowhere on the default ESX inventory, which shows no icons.

Can I add weapons this way? No. Weapons are defined separately (ox keeps them in data/weapons.lua), and an addon weapon needs streamed game files on top, so it’s a job of its own.

Is there a free way to add items in game? On ox_inventory, yes. spoodyItemCreator and Supreme OXItems are both free. The inventories and frameworks in this guide are on our free FiveM scripts list too.

Stuck on a specific inventory? Ask in our Discord with your framework, your inventory and the exact console line, and someone will point you at the fix.

YBN
YBN Limax Scripts
FiveM script developer at YBN. Building premium ESX, QBCore & Qbox resources.

Related Posts

Need scripts for your server?

Check out our premium FiveM resources — ESX, QBCore & Qbox supported.

Browse Premium Scripts → Free Scripts →