> ## Documentation Index
> Fetch the complete documentation index at: https://help.freakhosting.com/llms.txt
> Use this file to discover all available pages before exploring further.

# How to Configure the server.cfg File in FiveM

> Master the central brain of your FiveM server. Learn how to manage resources, security tokens, and professional branding within the server.cfg file.

## Architecting the Server Core

The `server.cfg` file serves as the central nervous system of your FiveM server. It dictates every fundamental aspect of your environment - from the specific resources and frameworks that define your gameplay, to the administrative permissions and security tokens required for public visibility. Establishing a well-structured and optimized configuration is essential for technical stability and providing a professional experience for your community.

<CardGroup cols={2}>
  <Card title="Difficulty" icon="gauge-low">
    Intermediate
  </Card>

  <Card title="Time" icon="clock">
    10 Minutes
  </Card>
</CardGroup>

***

## Identity & Professional Branding

Your server's public profile is defined by several key variables that determine how potential players discover and perceive your project within the Cfx.re masterlist.

```cfg theme={null}
sv_hostname "FREAKHOSTING RP | High Performance | Custom Assets"
sets sv_projectName "FREAKHOSTING Roleplay"
sets sv_projectDesc "A premium roleplay environment for serious players."
sets tags "roleplay, drifting, police, qb-core"
sv_maxclients 48
load_server_icon logo.png
```

* **Project Metadata:** `sv_projectName` and `sv_projectDesc` are utilized by the modern FiveM UI to provide a more detailed summary than the standard hostname.
* **Visual Recognition:** `load_server_icon` points to a 96x96 pixel `.png` file located in your root directory, providing a unique logo for your browser entry.

***

## Authentication & Authorization

To authorize your server's communication with the global masterlist and Steam services, you must implement valid security tokens.

<Tabs>
  <Tab title="License Key">
    The `sv_licenseKey` is mandatory for server initialization. Obtain your unique key from the official [Cfx.re Keymaster](https://keymaster.fivem.net/).
  </Tab>

  <Tab title="Steam API">
    The `steam_webApiKey` is required if your resources use Steam identifiers for player whitelisting or data storage. Generate your key at [steamcommunity.com/dev/apikey](https://steamcommunity.com/dev/apikey).
  </Tab>
</Tabs>

***

## Strategic Resource Loading Order

FiveM initializes resources sequentially. If a script depends on another framework (e.g., a car dealer script requiring a database wrapper), the dependency **must** be authorized first in the configuration.

<Steps>
  <Step title="System Foundations">
    Load basic engine requirements: `spawnmanager`, `chat`, and `mapmanager`.
  </Step>

  <Step title="Database Connectivity">
    Initialize your database bridge (e.g., `oxmysql` or legacy `mysql-async`) to ensure subsequent scripts can save data.
  </Step>

  <Step title="Core Framework">
    Deploy your primary gameplay logic, such as **QB-Core**, **ESX**, or **vMenu**.
  </Step>

  <Step title="Communication & Assets">
    Load voice resources like **pma-voice**, followed by your bracketed asset folders: `[cars]`, `[maps]`, and `[clothing]`.
  </Step>
</Steps>

<Tip>
  ### Organizational Optimization

  Instead of maintaining a massive list of hundreds of individual `ensure` lines, group your resources into bracketed subdirectories (e.g., `/resources/[legal_jobs]/`). You can then load every asset within that directory simultaneously using a single command: `ensure [legal_jobs]`.
</Tip>

***

<Note>
  ### Need Extra Help?

  If you encounter any issues, our support team is ready to assist:

  * **Live Chat:** Quick assistance via our website.
  * **Support Ticket:** [Open a Ticket](https://freakhosting.com/clientarea/submitticket.php)
  * **Discord:** [Join our Community](https://discord.gg/freakhosting)
  * **Email:** [support@freakhosting.com](mailto:support@freakhosting.com)
</Note>

<Tip>
  ### Save on Your Hosting

  Ready to get a new server? Use code **KB20** at checkout for **20% off** your first month!
</Tip>

***

<div align="center">
  **Last Updated:** January 2026 | **FiveM:** Core configuration verified.
</div>
