Skip to content

Installation ​

Requirements ​

  • A recent FiveM server artifact (Lua 5.4)
  • Node 18+ to build the NUI once

Nothing else is required: no database, no ox_lib, no streamed assets. Optional, auto-detected at start:

KindResourcesUsed for
Frameworkqbx_core, qb-core, es_extendedJobs and groups on rows and server actions, money for the shops and "Give money", character name, death state
Vehicle keysqbx_vehiclekeys, qb-vehiclekeysKey check for the built-in lock / unlock and "Give keys" (Config.Interact.lockMode = 'auto')
Inventoryox_inventory or the framework inventoryRepair kits for the context menu "Repair" option (Config.Context.repair.item)

Steps ​

  1. Put the resource in resources/ as np_menu. The NUI callbacks use https://np_menu/…, so keep the name.
  2. Build the NUI:
    sh
    cd web && npm ci && npm run build
    This creates web/dist, which fxmanifest.lua loads as the ui_page.
  3. Start it after the framework, because the bridge is picked once at start:
    cfg
    ensure qbx_core      # or qb-core / es_extended (optional)
    ensure np_menu
    ensure my_resource   # resources that register menus come after np_menu
  4. Give your staff the admin ace. It unlocks the dev / admin menu, the "Admin" tile in the quick menu and every admin server action:
    cfg
    add_ace group.admin np_menu.admin allow
    The ace name is Config.Admin.ace. Run npmenu_aces_reset (console or an admin) after changing aces at runtime so clients re-query them.

Test it

Press F10 as an admin for the dev menu, F1 for the quick menu, hold Left Alt for the radial wheel and hold G while looking at a vehicle for the context menu. /menusettings opens the player settings.

Optional next steps ​

  • Switch off built-in menus you don't want: Built-in menus.
  • Set a brand colour: Theming & settings.
  • Already using ox_lib menus? Turn on Config.OxCompat: ox_lib compatibility.
  • Standalone servers: groups map to aces. groups = 'police' on a server action checks np_menu.group.police:
    cfg
    add_ace group.police np_menu.group.police allow

Using np_menu from another resource ​

Call the exports directly:

lua
exports.np_menu:register({ id = 'my_menu', title = 'My menu', items = { ... } })
exports.np_menu:open('my_menu')

Or load the OOP wrapper in your fxmanifest.lua:

lua
shared_script '@np_menu/import.lua'

See Creating menus. Menus, radial items and context options that a resource registered are removed automatically when that resource stops.

Troubleshooting ​

SymptomFix
Nothing shows upweb/dist is missing. Build the NUI.
F10 says "no permission"Add the np_menu.admin ace to your group (step 4), then reconnect or run npmenu_aces_reset.
Shop purchases fail with "no framework"Standalone has no money. The built-in shops need qbx, qb or ESX.
Jobs / groups never matchThe framework started after np_menu. Fix the start order, or set Config.Framework explicitly.
Keys don't workPlayers can rebind them in Settings → Key Bindings → FiveM. The config only sets the defaults.
Preview image doesn't loadThe image host is not in Config.ImageHosts.

np_* FiveM resources