SimplisticNode

How much RAM does a FiveM server need?

A realistic guide to FiveM server RAM: what actually uses memory, sensible sizes for standalone, ESX and QBCore servers, and when to upgrade.

FiveM6 min read

It is one of the first questions anyone asks when they start a FiveM server, and the honest answer is: it depends on what you run. Two servers with the same number of players can need very different amounts of memory. This guide explains what actually uses RAM on a FiveM server, gives you sensible starting points, and shows you how to tell when it is time to move up.

The short answer

If you just want a number to start with, these ranges are a reasonable guide for most servers:

  • 2 GB: a test or development server, or a small standalone race, drift or freeroam server with a handful of scripts.
  • 4 GB: a new ESX or QBCore roleplay server with a sensible set of scripts and a modest number of players.
  • 6 GB: an active roleplay city with a full script list, some custom maps and busy evenings.
  • 8 to 12 GB: an established city with a large resource list, lots of custom vehicles and clothing, and a big community.
  • 16 GB and above: very large servers, heavy custom content, or communities that want plenty of headroom for events.

Treat these as starting points, not rules. Your scripts, your custom content and how well they are written matter far more than your slot count.

What actually uses memory

FXServer, the program that runs a FiveM server, is fairly light on its own. A fresh server with no framework and no extra resources uses very little. The memory goes on everything you add on top of it.

  • Resources and scripts. Every resource that starts takes some memory, and the Lua or JavaScript inside it keeps its own data in memory while it runs. A few hundred resources soon add up.
  • Your framework. ESX and QBCore load jobs, items and player data, and keep information about every online player in memory while they are connected.
  • Streamed content. Custom vehicles, clothing, maps and MLOs are mostly a storage and download cost, but a big asset library still adds to what the server has to keep track of.
  • Entities. The server tracks players, vehicles, peds and objects in the world. More players and more spawned entities mean more to track.
  • Badly behaved scripts. A script that keeps adding data and never clears it will slowly eat memory until the server restarts. This is the most common reason a server seems to need more RAM than it should.

If you run your database on the same machine, for example when you self-host or put everything on one VPS, MySQL or MariaDB needs its own share of memory too. Leave room for it rather than giving every last gigabyte to FXServer.

Why CPU matters just as much

FiveM leans heavily on single-thread CPU speed. A lot of the server's work happens on its main thread, so a slow core shows up as desync, rubber-banding and hitches even when there is plenty of free memory. If your server feels laggy but memory use looks fine, adding RAM will not fix it. Look at your scripts and your CPU instead.

That is why our FiveM hosting runs on high-clock Ryzen CPUs. Memory decides how much you can run, but clock speed is a big part of what keeps a busy city feeling smooth.

Players versus scripts

It is tempting to size a server by its player slots, but players are rarely the main driver of memory use. Twenty players on a server with a huge, unoptimised script list can use more than sixty players on a lean, well-maintained one. When you are working out what you need, think about it in this order:

  1. Which framework you run, if any.
  2. How many resources you start, and how heavy they are.
  3. How much custom content you stream: vehicles, clothing, maps and MLOs.
  4. How many players are online at your busiest time.

Slot count also has a limit that has nothing to do with hardware. Cfx.re, the team behind FiveM, sets how many slots a server can open, and larger slot counts need a paid Cfx.re tier. Check their current terms before you plan a very large server.

Signs you need more RAM

  • Memory use sits close to your plan's limit during your busiest hours.
  • The server crashes or stops on its own, with out-of-memory errors in the console.
  • You are about to add a big batch of new content, such as a large car pack or several new MLOs.
  • You have tidied up your scripts and memory use is still high on a normal evening.

One sign that does not mean you need more RAM: memory that climbs steadily from every restart and never levels off. That usually points to a leaking script. More memory only means it takes a little longer to run out, so find the leak first.

How to check what is using memory

  1. Restart the server and note the memory use once everything has finished starting. That is your baseline.
  2. Watch the resource usage in txAdmin or your game panel across a normal day, including your busiest hour.
  3. If memory keeps climbing, stop recently added resources one at a time on a test copy of your server to find the culprit.
  4. In game, press F8 and type resmon 1 to see how much each resource costs on the client. Scripts that are heavy for players are often heavy on the server too.
  5. Set up scheduled restarts in txAdmin to clear out slow leaks while you track them down. Many busy servers restart every few hours.

Keep a note of your baseline each time you add something big. It makes it much easier to spot which change pushed memory up.

Ways to use less memory

  • Remove resources you do not use. Old test scripts and duplicate features left in server.cfg still load.
  • Prefer well-maintained scripts from reputable developers, and keep them updated.
  • Be selective with custom content. Ten great cars are better than two hundred nobody drives.
  • Clean up spawned vehicles and objects that are no longer needed, rather than letting them pile up.
  • Keep your artefacts reasonably up to date, as newer server builds often include fixes and improvements.

Picking a plan

Our FiveM plans run from 2 GB to 32 GB of RAM, in our UK (Newcastle) or US (Salt Lake City) locations. Every plan comes with txAdmin, MySQL databases, automatic artefact updates and DDoS protection. Here is roughly how they line up with the ranges above:

  • Starter (2 GB): testing, development and small standalone servers.
  • Roleplay (4 GB): a new ESX or QBCore city finding its feet.
  • City (6 GB): our recommended plan, and the size most active roleplay servers should start with.
  • Metropolis (8 GB) and Megacity (12 GB): established cities with big resource lists and lots of custom content.
  • Enterprise (16 GB) and above: very large servers and communities that want plenty of headroom.

If you are unsure, go one size up from what you think you need and watch your memory for a couple of weeks. It is much easier to spot a leak or plan an upgrade when you are not already up against the limit. You can scale up any time, and moving from another host is straightforward: see our guide to moving an existing server.

The bottom line

For most new roleplay servers, 4 to 6 GB is a comfortable place to start. Standalone and test servers can live happily on 2 GB, and large cities with a lot of custom content will want 8 GB or more. Whatever you pick, measure your real usage, fix leaking scripts before throwing memory at them, and remember that a fast CPU matters just as much as RAM.

Ready to size your city?

FiveM plans from 2 GB to 32 GB on high-clock Ryzen, with txAdmin and MySQL ready from the moment you order.