Microsoft Defender is on by default in Windows Server and scans every file that is opened. On a game server that loads thousands of files (FiveM resources, Minecraft or ARK mods) that shows: slower starts and stutters. And sometimes it flags a legitimate server file as suspicious and quarantines it.
Adding the exclusion
In PowerShell as administrator, with your server's folder:
Add-MpPreference -ExclusionPath "C:\FXServer"
Optionally, the server executable too:
Add-MpPreference -ExclusionProcess "FXServer.exe"
Checking and removing
# See current exclusions
Get-MpPreference | Select-Object -ExpandProperty ExclusionPath
# Remove one
Remove-MpPreference -ExclusionPath "C:\FXServer"
If Defender has already taken a file
Open Windows Security → Virus & threat protection → Protection history. It shows what was blocked and, if you are sure it is yours and legitimate, you can restore it.
Use some judgement
- Exclude only the server folder, never all of
C:\, Downloads or the Desktop. - Only with trusted software: resources and mods from their official source. A "leaked" or pirated script inside an excluded folder is exactly what Defender will not be able to stop.
- Do not turn Defender off completely. With the folder exclusion you get the performance and keep the protection for the rest of the system.