Skip to main content
📘 This content originated from JavaPipe’s website. JavaPipe has now merged with Mochahost, providing an improved range of hosting services with added benefits and dependable service quality. Check out the fastest hosting plans here: Managed Linux VPS

Setting Up FiveM Server on Windows VPS or Linux VPS

FiveM server can be set up on both Windows VPS and Linux VPS plans. JavaPipe recommends the Linux option due to its resource efficiency, ability to handle more traffic, and easier mitigation of DDoS attacks.

FiveM on Windows VPS

Requirements:

Installation Steps:

  1. Create a new folder (for example D:\\FXServer\\server).
  2. Download the latest master branch build for Windows from the artifacts server.
  3. Extract the build into the directory previously created, using any archiving tool (WinRAR or 7-zip).
  4. Clone cfx-server-data in a new folder outside of your server binaries folder, for example, D:\\FXServer\\server-data.
    4b. git clone https://github.com/citizenfx/cfx-server-data.git server-data
  5. Make a server.cfg file in your server-data folder (copy the example server.cfg file below into that file).
  6. Generate a license key at https://keymaster.fivem.net.
  7. Set the license key in your server.cfg using sv_licenseKey “your_license_here”.
  8. Run the server from the server-data folder. For example, in a plain Windows command prompt (cmd.exe) window:
cd /d D:\FXServer\server-data
D:\FXServer\server\FXServer.exe +exec server.cfg

FiveM on [Linux VPS]

  1. On a new folder (for example mkdir /home/username/FXServer/server), download the latest master branch build for Linux from the artifacts server (copy the URL for the latest server version and use wget <url> to download it).
  2. Extract the build to the directory that was previously created, using cd /home/username/FXServer/server && tar xf fx.tar.xz (you need to have xz installed, on Debian/Ubuntu this is in the xz-utils package).
  3. Clone cfx-server-data in a new folder outside of your server binaries folder.
    4b. For example git clone https://github.com/citizenfx/cfx-server-data.git /home/username/FXServer/server-data
  4. Make a server.cfg file in your server-data folder (copy the example server.cfg file below into that file).
  5. Generate a license key at https://keymaster.fivem.net.
  6. Set the license key in your server.cfg using sv_licenseKey “yourLICENSEhere”.
  7. Run the server from the server-data folder.
    8b. bash /home/username/FXServer/server/run.sh +exec server.cfg

Common Issues:

  • If you don’t get any ‘resources found’, and it says ‘Failed to start resource’, you didn’t ‘cd’ to the right folder.- If no resources start and you can’t connect, ensure you added +exec.
  • If no resources get started, and you can’t connect, you didn’t add +exec.
  • If you get ‘no license key was specified’, one of the above things applies.

Example server.cfg

An example server.cfg file is provided below:

Configuration for FiveM Server