What is a firewall?
A firewall is a software (or hardware) security component used to filter traffic on a computer network based on configured rules. It can be used to secure access to a privileged resource, or filter undesirable traffic from the internet. In this guide, we will explain how to setup port-forwarding to your FiveM server.
By default, Windows Server comes with strict firewall rules applied to inbound traffic, so to run a FiveM server accessible over the internet some changes must be made.
How to setup the Windows firewall for FiveM
First, log into your Iceline Windows Server VPS using remote desktop or VNC.
After logging in, open the start menu and search for Windows Defender Firewall
Open the program and click on Advanced Settings on the left sidebar.
With the firewall management window open, right-click (1) Inbound Rules and select (2) New Rule
In the rule wizard, select Port and click Next
Now select TCP as the protocol and 30120 as the port, which is the default for FiveM servers.
Press Next twice and you should end up in the last step, Name. You can use whatever you want in this field, but using something short and to the point will make it easier to find this rule in the future if you wish to remove or modify it.
Once you click Finish the VPS will now allow traffic on port 30120 using TCP.
However, FiveM also requires port 30120 to be available over UDP. To do that, follow the same steps outlined above but in the Protocol and Ports section, select UDP instead of TCP.
In this guide, we have tried to explain how to setup port-forwarding to your FiveM server, but if something was unclear or outdated, feel free to reach out to us by creating a ticket.