How to do port forwarding on any router (guide with pictures)

Last updated 29/09/2025

Photo of author

Written by Eleanor Vance

Avatar Michale Dang

Fact-checked by Michale Dang

Have you ever faced a connection error while gaming online, dealt with slow torrent speeds, or been unable to access your security camera remotely? The solution is often a technique called port forwarding. Think of it as giving your router a special instruction to open a private, direct path for the data you actually want to receive.

In today’s connected homes, your router’s default firewall acts as a digital gatekeeper, blocking unwanted traffic for your security. While this is essential, it can sometimes block the very connections you need. Learning how to do port forwarding is the key to taking control of that gate and unlocking your network’s full potential.

I have over a decade of experience setting up home and small office networks. I’ve seen countless users give up on hosting a game server out of frustration. Many follow confusing guides. As a result, they accidentally open their networks to security risks. This isn’t just a trick for IT experts; it’s a learnable skill for any user.

In this comprehensive guide, you’ll discover:

  • What port forwarding is and the most common reasons you might need it.
  • The 3 essential preparation steps you must complete first.
  • A port forwarding step-by-step guide with clear pictures.
  • How to check if a port is open and the key tips to stay safe.

Don’t let a simple network setting limit what you can do. Let me walk you through every step, demystifying the process so you can get connected with confidence – starting now.

1. What is port forwarding, and why do you need it?

Before we dive into the “how-to,” it’s crucial to understand the “what” and the “why.” The best way to explain port forwarding is to visualize your home network as a large apartment building. In this analogy, your router acts as the security guard at the front desk.

1.1. What is Port Forwarding?

Your router’s primary job is to act as a firewall, protecting all the devices on your network. Like a security guard, its default rule is to block all unsolicited incoming traffic. If a random data packet from the internet arrives, your router has no idea which device (which apartment) it’s for, so it safely turns it away.

Port forwarding is simply a specific instruction you give to your router (the guard). You’re telling it: “If a specific type of visitor (data) arrives asking for a specific door number (a port), please send them directly to this specific apartment (your device).”

You are creating a pre-approved, direct path through your firewall for traffic you know and trust.

1.2. Why do you need it?

For most of your online activities, like browsing websites or streaming Netflix, you don’t need port forwarding because your device initiates the connection. But you will need it for situations where you need an external device to initiate a connection to you.

The most common use cases I encounter are:

  • Gaming: This is the big one. Port forwarding allows you to host your own game servers. It also enables direct connections with friends. Additionally, it often changes your NAT Type from “Strict” or “Moderate” to “Open.” This change significantly improves matchmaking and reduces lag.
  • Remote Access: It allows you to connect reliably to devices on your home network from anywhere in the world. For example, you can view your security camera feed. You can also access files on a home media server, like Plex.
  • Hosting Servers: If you want to run a personal website or a dedicated server for games like Minecraft, port forwarding is essential for allowing others to connect.
  • P2P File Sharing: For applications like torrent clients, opening a port allows you to connect to more peers, which can dramatically improve your download and upload speeds.
Port Forwarding
Port Forwarding

2. The preparation checklist: 3 things you need before you start

This is the most important part of the entire guide. From my years of troubleshooting failed network setups, I can tell you that 90% of port forwarding failures happen because of inadequate preparation.

Before you even think about logging into your router, you need three key pieces of information. Taking five minutes to gather these now will save you hours of frustration later. Think of it as gathering your ingredients before you start cooking.

2.1. Step 1: Find your router’s IP address

To give instructions to your router, you first need to know where to find its control panel. This is its local IP address, also known as the “Default Gateway.”

On Windows: The quickest way is with the Command Prompt.
  1. Press the Windows Key + R, type cmd, and press Enter.
  2. In the black window that appears, type ipconfig and press Enter.
  3. Look for the line that says “Default Gateway.” That number (usually 199.168.1.1 or 199.168.0.1) is your router’s address.
Find your router’s IP address On Windows (1)
Find your router’s IP address On Windows (1)
Find your router’s IP address On Windows (2)
Find your router’s IP address On Windows (2)
Find your router’s IP address On Windows (3)
Find your router’s IP address On Windows (3)
On macOS:
  1. Go to System Settings > Network.
  2. Select your active connection (Wi-Fi or Ethernet) and click Details….
  3. Go to the TCP/IP tab. The address listed next to “Router” is the one you need.

Write this number down. This is the address you’ll type into your web browser to access your router’s settings.

2.2. Step 2: Set a static IP address for your device

This is a critical, often-skipped step. By default, your router uses a system called DHCP to hand out temporary, or “dynamic,” IP addresses to your devices. This is like a hotel giving you a random room number when you check in. If your PC’s internal IP address changes, your port forwarding rule will be pointing to the wrong “room,” and it will stop working.

To prevent this, you need to give your device a permanent “room number” – a static IP.

The Recommended Method (DHCP Reservation)

The most efficient approach is to modify your router’s settings. Log in, go to the DHCP or “LAN Settings” section, and find the option labeled “DHCP Reservation” or “Static IP.” Here, you can assign a permanent private IP address to your device’s unique MAC address, directing your router to consistently assign this device the same IP address.

Set a static IP address for your device (1)
Set a static IP address for your device (1)
The Manual Method

Alternatively, you can configure the static IP manually in your device’s network settings (on Windows, PS5, Xbox, etc.). You’ll need to provide:

  • IP Address: Choose one from your network’s range (e.g., 192.168.1.150).
  • Subnet Mask: Usually 255.255.255.0.
  • Default Gateway: Your router’s IP from Step 1.
Set a static IP address for your device (2)
Set a static IP address for your device (2)

2.3. Step 3: Know which ports to forward

Finally, you need to know which “doors” you need to open. Every application or game uses specific, numbered ports for communication.

  • How to find them: The easiest way is with a quick Google search for “[game or application name] port forward numbers”. Reputable sources like the game developer’s official support site or dedicated communities are your best bet.
  • A Gaming Example: From my experience setting up consoles, getting an Open NAT Type for Call of Duty on a PS5 requires forwarding a specific list of ports. The official port forwarding for PS5 list from Activision includes TCP: 1935, 3478-3480, and UDP: 3074, 3478-3479.

Once you have these three pieces of information – your router’s IP, your device’s new static IP, and the list of ports – you are ready to begin the main process.

3. How to open ports on your router: The main guide

With all your ingredients from the preparation checklist, you’re now ready to cook. This is the main port forwarding step-by-step guide.

Remember, the user interface will look slightly different for every router brand, but the core information you need to enter is always the same. The key is to find the right menu.

3.1. Step 1: Log in to your Router

Open a web browser (like Chrome or Firefox) and type the router IP address you found in the preparation step into the address bar. Press Enter. You will be taken to your router’s login page. Enter the username and password.

Pro Tip

If you’ve never changed it, the default login information is often printed on a sticker on the bottom of your router. Common defaults are admin/admin or admin/password.

3.2. Step 2: Locate the Port Forwarding Settings

This is the treasure hunt part. You need to navigate through your router’s menus to find the port forwarding section. Based on the hundreds of routers I’ve configured, look for a menu with one of these common names:

  • Port Forwarding (most common)
  • Virtual Servers (common on TP-Link and D-Link routers)
  • Applications & Gaming (common on Linksys and some Netgear routers)
  • Firewall or NAT Forwarding

It’s almost always located under an “Advanced” or “WAN” settings tab.

3.3. Step 3: Create a New Rule

Once you’re in the right section, you’ll see a table of existing rules (which is likely empty) and an option to create a new one. Click the button that says “Add New Rule,” “Create New Service,” or something similar.

3.4. Step 4: Fill in the Details

This is where you’ll use the information from your checklist. You’ll see a form with several fields to fill in.

  • Service Name / Description: Give the rule a name you’ll recognize, like “PS5 Gaming” or “Minecraft Server”.
  • Port Range (or External/Internal Port): Input the port number(s) you wish to open. For a single port, enter the same number in both the start and end fields. If you’re opening a range (e.g., 3478-3480), enter it as specified.
  • Device IP (or Internal IP): Enter the static IP address you set for your device in the preparation step (e.g., 192.168.1.150).
  • Protocol: Select the correct protocol – TCP, UDP, or Both/All – as specified by the game or application’s requirements.

3.5. Step 5: Save and Apply the Rule

Click the “Save” or “Apply” button to save your new rule. Some routers may require a reboot to apply the changes.

That’s it! You’ve successfully learned how to open ports on your router. The final step is to verify that it worked.

How to open ports on your router?
How to open ports on your router?

4. Verification and security: Did it work and is it safe?

You’ve created the rule in your router, but how do you know if it actually worked? And more importantly, how do you make sure you haven’t opened your network to unnecessary risks? This final stage is about verification and smart security practices.

4.1. How to check if a port is open

Before you launch your game or app, it’s a great idea to confirm that the port is now visible to the outside world. From my experience, this simple check saves a lot of time troubleshooting later.

The easiest method is to use a free online port checking tool.

Make sure the application or game that needs the port is running on your device. The port won’t show as “open” if no application is actively “listening” on it.

On that same device, go to a website like YouGetSignal.com/tools/open-ports/ or PortChecker.co.

Enter the port number you just forwarded into the tool’s text box.

Click “Check.”

Open (Green)

Congratulations, your port forwarding was successful! The tool was able to reach the application through the open port on your router.

Closed (Red)

The port is not open. This means there’s a mistake in your configuration or something else is blocking the connection. Double-check your device’s static IP, the port numbers you entered, and your computer’s own software firewall to ensure it’s not blocking the connection.

4.2. Is port forwarding safe? Key security tips

Now for the critical question: Is port forwarding safe? By its very nature, you are creating a deliberate exception in your firewall, which introduces a level of risk. However, you can mitigate these risks significantly by following a few essential security practices.

As a security consultant, these are the non-negotiable rules I insist on:

  • Only open what you need: Be precise. Never forward a huge range of ports if an application only needs one or two. The fewer open doors, the smaller the attack surface.
  • Use strong passwords: Your router’s admin password should be strong and unique. More importantly, the device you are forwarding the port to (like your PC or NAS) must also have a strong password. An open port to a device with a weak password is an open invitation for an attacker.
  • Keep everything updated: Regularly update the firmware on your router. Just as importantly, keep the software on the device you’re forwarding to (your game, your server software, your camera’s firmware) up to date. Updates often patch critical security vulnerabilities.
  • Disable when not in use: If you only host a game server on the weekends, get into the habit of disabling the port forwarding rule during the week. A port that isn’t open cannot be attacked.
Key security tips
Key security tips

5. Troubleshooting and alternatives

Even with a perfect setup, you can sometimes run into roadblocks. Over the years, I’ve seen a few common issues trip people up. Here’s how to handle them, along with some modern alternatives to manual port forwarding.

Common Problems
  • Double NAT: This is the most frequent and frustrating problem I encounter. “NAT” stands for Network Address Translation, the process your router uses to manage your private network. “Double NAT” occurs when you have two devices on your network, both trying to act as a router. This is very common if your ISP provides a modem/router combo unit and you’ve plugged your own Wi-Fi router into it. The port-forward rule you set on your own router is blocked by the first router.
    • The Fix: You need to either put the ISP’s device into “bridge mode” (which turns off its router functions) or set up the same port forwarding rule on both devices.
  • ISP Firewall / Blocked Ports: Some Internet Service Providers, especially on cellular or satellite networks, use a large-scale NAT (called CGNAT) or actively block incoming connections and certain ports for security reasons. If your port checker shows “closed” even after a perfect configuration, your ISP might be the one blocking it. In this case, you’ll need to contact their support.
Port Forwarding without router access

What if you can’t access your router’s settings at all? This is common if you live in a dorm, an apartment with shared internet, or are on a corporate network.

  • Solution 1 (The Easiest & Safest): Utilize a VPN with Port Forwarding, which is the optimal solution for port forwarding when you lack router access. Some VPN providers, such as Private Internet Access and Proton VPN, offer this feature. It enables you to open a port on the VPN server, which then forwards traffic to you through the secure VPN tunnel. This way, you can enjoy the advantages of an open port without modifying your router’s settings.
  • Solution 2 (Advanced): Use a Tunneling Service. For tech-savvy users, services like ngrok can create a secure tunnel from a public URL directly to an application running on your local machine. This is a powerful tool for developers but can be complex to set up for gaming or general use.

6. FAQ about how to do port forwarding​

You’ve learned the steps, the risks, and the solutions. Here are some quick, direct answers to the most common questions that come up when learning how to do port forwarding.

What’s the difference between UPnP vs. port forwarding?

The main difference is control vs. convenience. Port forwarding is a manual process where you specify exactly which port opens to which device. UPnP (Universal Plug and Play) is an automatic process where devices on your network can ask the router to open ports for them. While convenient, UPnP is considered a significant security risk because you don’t always know what ports are being opened.

Will port forwarding increase my internet speed?

No, it will not increase your overall internet speed from your provider. However, port forwarding for torrenting can dramatically increase your P2P download and upload speeds by allowing your client to make more direct connections to other peers in the swarm.

Do I need to set up port forwarding to use a VPN?

No. For 99% of normal VPN uses (like browsing, streaming, and enhancing privacy), you do not need to set up port forwarding. You only need a VPN with port forwarding for specific, advanced tasks like optimizing torrent performance or hosting a game server through the VPN connection.

How do I know which port to forward for a game?

The best and most reliable way is to search online for “[game name] port forward numbers”. The game developer’s official website or trusted gaming community wikis will often publish a list of the specific TCP and UDP ports required for the best connection.

7. Conclusion

Learning how to do port forwarding is a valuable skill. It gives you greater control over your home network. This knowledge can unlock a better online experience for gaming. It also enhances hosting and file sharing. While the process might seem technical at first, it’s a logical sequence that anyone can master.

Your Port Forwarding Checklist:

  • [✓] Prepare: Find your router’s IP, set a static IP for your device, and identify the correct ports to open.
  • [✓] Execute: Log into your router and create a new port forwarding rule with the information you gathered.
  • [✓] Verify: Use an online tool to check if the port is open and confirm your setup was successful.
  • [✓] Secure: Always remember that an open port is a potential security risk. Use strong passwords and disable rules when they are no longer needed.

Don’t be intimidated by your router’s settings. By following this step-by-step guide, you’ve learned how to confidently and safely configure your network to meet your specific needs. To learn more tech tricks that help you master your digital world, explore the other guides in our Tech How-To Simplified section from Safelyo.

Photo of author

Eleanor Vance

Technology Analyst & Writer

I’m a dedicated technology analyst and writer at Safelyo, passionate about demystifying the complexities of the digital world for everyday users and businesses. With a keen eye for detail and a knack for clear communication, I specialize in breaking down intricate topics like VPNs, antivirus software, and AI automation into understandable and actionable insights.

Leave a Comment

Related Posts You Should Read

What does obfuscate mean​?

What does obfuscate mean? How it hides your VPN traffic

You may have seen the word ‘obfuscate’ in a VPN’s settings or a cybersecurity article and wondered, What does obfuscate mean exactly? In simple terms,...

NordVPN dedicated IP

NordVPN Dedicated IP review (2025): Is it worth the extra cost?

You’re a NordVPN user, enjoying the security of a top-tier VPN. But you still run into frustrating blocklists, endless CAPTCHA, or can’t get reliable remote...

Does VPN encrypt data?

Does a VPN encrypt data? Yes, and here’s how

One of the first questions many people have is, Does a VPN encrypt data? The simple answer is yes. In fact, encryption isn’t just a...

Don't miss anything! Sign up for our newsletter

Always up to date with the latest news, promotions and reviews.

We respect your privacy. Your information is safe and you can easily unsubscribe at any time.