> ## 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 Fix the FiveM Server Thread Hitch Warning

> Fix the FiveM server thread hitch warning: what the timer interval means, how to find the slow resource with the profiler and the usual script causes and fixes.

The FiveM warning `server thread hitch warning: timer interval of … milliseconds` means one tick of the server's main thread, which runs your server scripts, took that long. A resource blocked it, usually with a heavy loop, a slow database query or too many events. Record a profile with `profiler record 500` in the console to find the resource, then fix, update or remove it.

| Difficulty | Time | Works on | Panel page |
| - | - | - | - |
| Intermediate | 20 minutes | Every FREAKHOSTING FiveM server | **Console**, **Files**, **Statistics** |

## Is a server thread hitch warning a problem?

* **A few warnings at start-up** are normal while resources load.
* **Warnings that keep coming while players are online** need fixing. Players notice delays, rubber-banding and slow scripts.
* **The number matters.** It is how long the thread was busy, in milliseconds. A one-off warning is usually harmless; a steady stream of large numbers is not.

A similar warning names the **sync thread**, which handles OneSync. The approach below works for both. For the network version, see [network thread hitch warning](https://help.freakhosting.com/games/fivem/troubleshooting-network-thread-hitch-warning-in-fivem-servers.md).

## How to find the slow resource with the profiler

FXServer has a built-in profiler. Run it while the hitches happen.

**1. Start a recording**

In the **Console**, type:

```text theme={null}
profiler record 500
```

This records the next 500 frames. Type `profiler status` to see how far it is.

**2. Save it**

When it has finished, type:

```text theme={null}
profiler saveJSON profile.json
```

**3. Download it**

Find `profile.json` in **Files** and download it. It is saved in the folder the server program runs from.

**4. Open it in Chrome**

Open a new tab in Google Chrome, press **Ctrl** + **Shift** + **I**, go to the **Performance** tab and load the file. Long bars show which resource used the time.

Details: [Using the profiler](https://docs.fivem.net/docs/scripting-manual/debugging/using-profiler/) in the FiveM documentation.

## What causes server thread hitches?

| Cause | Fix |
| - | - |
| Loops without a wait | Every `while true do` loop needs a `Wait()`. Use the longest wait that works, for example `Wait(500)` instead of `Wait(0)`. |
| Slow or blocking database queries | Use the async functions of `oxmysql` and don't run queries in fast loops. |
| Looping over all players often | Run the loop less often, or only when something changes. |
| Too many events | Don't trigger client events for every player (`-1`) every tick. Send only to the players who need it. |
| Outdated or duplicate scripts | Update resources, remove scripts you don't use, and use the **Recommended** FXServer build on [Artifacts](https://help.freakhosting.com/games/fivem/how-to-update-your-fivem-server-artifact.md). |

If a paid script causes the hitches, send its author your profile file.

## Is my server too small?

Open **Statistics** in the sidebar. If CPU or memory sits at your plan's limit during busy hours even after you fixed slow scripts, the server needs more room. Upgrade in the [client area](https://freakhosting.com/clientarea), or [open a ticket](https://freakhosting.com/clientarea/submitticket.php) with a log link from **Share log** on the console. See [how to view server statistics](https://help.freakhosting.com/portals/game-panel/how-to-view-server-statistics.md).

## Frequently asked questions

### What does "timer interval" mean in the hitch warning?

It is how long one server tick took, in milliseconds. A tick should be short, so a large number means a resource kept the thread busy.

### Does a hitch warning mean my host is lagging?

Usually not. In most cases one of your resources is the cause, which the profiler shows. Check **Statistics** to rule out a full CPU or memory.

### Does a daily restart help?

A restart clears memory that scripts don't release. It doesn't fix a slow script. Set one up in [Schedules](https://help.freakhosting.com/portals/game-panel/how-to-configure-schedules-and-tasks.md) or in txAdmin, not both.

### What is citizen-server-impl in the warning?

It is the part of FXServer that prints the warning. It doesn't mean FXServer itself is broken.

## Related guides

> **[FiveM server guide](https://help.freakhosting.com/games/fivem/fivem-server-hosting-guide.md)**
>
> Every FiveM guide in one place.

> **[Network thread hitch](https://help.freakhosting.com/games/fivem/troubleshooting-network-thread-hitch-warning-in-fivem-servers.md)**
>
> The network version of the warning.

> **[Console commands](https://help.freakhosting.com/games/fivem/fivem-server-console-commands.md)**
>
> profiler, ensure and more.

> **[OneSync explained](https://help.freakhosting.com/games/fivem/understanding-onesync-infinity-vs-legacy.md)**
>
> Sync modes and performance.

> [!NOTE]
>
> **Checked by the FREAKHOSTING team** against the official [FiveM profiler documentation](https://docs.fivem.net/docs/scripting-manual/debugging/using-profiler/) on 29 October 2026. Details may change when FiveM or the resource is updated.

***

> [!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)

> [!TIP]
>
> ### Save on Your Hosting
>
> Ready to upgrade your hosting? Use code **KB20** at checkout for **20% off** your first order!

***

**Last Updated:** October 2026


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.