← All posts
23 October 2026 · 4 min read

Running your own FiveM download cache with nginx: is it worth it?

What a self-hosted nginx cache for FiveM downloads involves, where it falls short, and how it compares with a managed FiveM CDN.

Some server owners consider running their own download cache: nginx on a VPS, sitting between the server and the players. It can work, and the Cfx.re proxy setup documentation includes an example config. Before you build one, it is worth knowing what it takes to keep it running and what it still does not do.

What you take on

  • A separate VPS with enough disk space for all your resources, and a traffic allowance big enough for every download your players make.
  • A domain name and a TLS certificate that keeps renewing.
  • An nginx cache config that suits your server. Cache size, how long files are kept and how many requests reach your server at once all need tuning. The example config drops files after two quiet hours, so a server that is empty at night starts every morning with a cold cache.
  • Keeping the VPS updated and secure.
  • Monitoring. FiveM has no fallback for downloads, so if the VPS or nginx goes down, players cannot join until you fix it. More on that.

What it still does not do

  • It sits in one place. Players far from the VPS still download from far away, so it takes load off your server but does not make their downloads faster.
  • Anyone with a file URL can download from it. nginx does not know who is connected to your server, so paid assets can be pulled by anyone who finds the address.
  • Your server's own file endpoint stays open. Anyone who finds your server's IP can still download from it directly, unless you lock that down as well.
  • Updates need care. After you change a resource, the cache has to hand out the new files and not the old ones. A wrong setting means players get outdated files or the cache stops helping.

What it costs

A VPS with enough disk and traffic for a busy server costs somewhere between €5 and €20 a month, plus your time to set it up and keep it running. And if it goes down on a busy evening, that time is needed at the worst moment.

The same result with FiveMCDN

FiveMCDN does this job without the VPS. You add two lines to your server.cfg and restart:

server.cfg
# fivemcdn.com: add these 2 lines to server.cfg, then restart your server
fileserver_add ".*" "https://cache.fivemcdn.com/t/ab12cd34/files"
set adhesive_cdnKey "k9f2Qv7pXn3wLtB8sZ1aRcYd"
  • Files are served from Cloudflare locations near each player, not from one data center.
  • Only players connected to your server can download your files.
  • Our own invalidation system picks up updates automatically. There is nothing to tune or purge.
  • Two optional lines lock your server's file endpoint so it only answers the CDN.
  • No VPS, nginx or certificates to look after.

The Free plan includes 10 GB of cache storage and 1 TB of bandwidth a month, and paid plans start at €7.50 a month. See the quickstart or pricing.

Take downloads off your server

Two lines in server.cfg. Free plan, no card needed.

Start free
More from the blog