[Tutorials] How to Port Forward on OPNsense

[Tutorials] How to Port Forward on OPNsense

OPNsense logo
OPNsense

During my use of OPNsense, I wanted to do port forwarding for my LibreSpeed speed test tool, but after some searching, I couldn’t find any helpful resources and tutorials about OPNsense, so I decided to write a simple tutorial here to help you configure OPNsense port forwarding.

First, let’s go to Firewall -> NAT -> Port Forward. Then click Add button at the top right corner.

OPNsense port forward 1

Secondly, change the Destination to WAN address since we want to access LibreSpeed from the WAN interface. Then pick a random port that you want to access your LibreSpeed externally. Here I use 12345 as the port.

OPNsense port forward 2

Let’s continue on the Port Forward page. My LibreSpeed running as a Docker container in my UNraid server, so the Redirect target IP is the IP address of my LibreSpeed address, in my case, the address is 192.168.1.199. Then Redirect target port is the port that accesses my LibreSpeed which is 6580.

OPNsense port forward 3

Then you can give it a name as you like, I will call it LibreSpeed to help me remember it. Then keep the remaining settings as the default configuration, hit Save. OPNsense will create firewall rules for us automatically. Finally, Apply changes on the main page to make it live.

OPNsense port forward 4

Now, you can access your internal sources from the internet by using your IP address and port. If you have a domain name and DDNS setup on your OPNsense, you can easily access your internal page by using your domain name and port, for example, home.example.com:20000

I hope this tutorial can help you a little bit when you explore OPNsense, it is a great firewall system, and I like it a lot! If you want to see more tutorials about OPNsense, leave a comment below. Want to see more fun stuff I made, click HERE to go to the main page.

Like this post? Please share this:

4 thoughts on “[Tutorials] How to Port Forward on OPNsense

  1. Thank you for this, for some reason the newest pfsense doesn’t like my server so I switched to OPNsense. I have spent a couple of days trying to get the reverse proxy on unraid to work with OPNsense with no luck. Stumbled across this post and following the steps, everything is working 100%. Thank you very much for this tutorial.

  2. i recently switched from a tp link wifi router and had all kinds of ports forwarded and open.

    i am using opnsense now on a protectli box and i can’t get any of the ports to forward.

    ive used several examples your example and none of my ports forward

    i can’t remote desktop from wan side but everything is good in lan side.

Leave a Reply

Your email address will not be published.