FiveM server takes forever to start: Defender exclusion and fixes
Windows Defender can slow FXServer startup. Add a folder exclusion with the PowerShell command from the docs, restart, and check the console.
Short answer: On Windows, Microsoft Defender can slow down server startup because it scans FXServer files. The official FiveM docs give a PowerShell command that adds your server folder to Defender's exclusion list. Run it, restart the server, and check the console if startup is still slow.
Last checked: 2026-12-02.
Why startup gets slow
The official Server Issues page says that Microsoft Defender Antivirus may slow down server startup by scanning FXServer files on Windows servers. The page does not give timings, so measure your own startup before you change anything. You will need that number to see if the fix worked.
Steps to fix it
- Open PowerShell as administrator. Press the Windows key and type
PowerShell. Right-click Windows PowerShell in the results and click Run as administrator. If Windows asks for permission, click Yes. The window title shows that it runs as Administrator. - Add the exclusion. Run the command below. Replace the path with the folder where your FXServer files are. The docs use
C:\FXServer\as the example.
``powershell Add-MpPreference -ExclusionPath 'C:\FXServer\' ``
The command finishes without an error message. Defender now skips that folder during scans.
- Restart the server and time it. Start the server the same way you did before. Compare the time with your first measurement.
- Check the console if it is still slow. The official page says that adding resources increases startup time. It also says that unusually long startups can be caused by errors or warnings in the console. Fix those messages first.
Verify the fix
Open the server console and start the server. Startup should take less time than your first measurement, and the console should show no new errors from Defender-related scans. If the time is about the same, the exclusion is probably not the cause, so go to the troubleshooting section.
If it does not work
- Check the path in the command. It must match the folder your server runs from. A wrong path adds an exclusion for a folder that does not hold your server.
- Look for errors and warnings in the server console. Slow startups often come from a resource that fails or waits.
- Check how many resources you added recently. The docs say each added resource increases startup time.
On the cfx.re forum, a player reported that adding a Defender exclusion for the server and cache folders fixed slow restarts. The original poster confirmed it worked, and the thread title is marked as solved.
Frequently asked questions
Is it safe to add a Defender exclusion?
Add only the folder that holds your server files. An exclusion tells Defender not to scan that folder. Do not add a whole drive.
Does this apply to Linux servers?
No. The official docs mention this problem only for Windows servers.
Why is my server still slow after the exclusion?
The docs say that adding resources increases startup time. Check the server console for errors or warnings, and fix or remove the resources that fail.
Sources
- FiveM docs: Server Issues, Troubleshooting Slow Server Startups
- [cfx.re forum: [SOLVED] Server taking forever to start up](https://forum.cfx.re/t/solved-server-taking-forever-to-start-up/4899406)
FiveM.tools was founded with sponsorship from Nyru.