How to check if a port is open
To see if a port is open to the internet, test it from outside your network with the FernTool open port checker. To see whether a program on your computer is listening, use the built-in commands below.
1. From the internet (what others see)
Open the port checker. Your public IP is filled in; choose the port (for example 25565 for Minecraft or 32400 for Plex) and press Check. “Open” means the whole path works: router forward, firewall and the program itself.
2. Is a program listening? (local)
- Windows (PowerShell):
Get-NetTCPConnection -State Listen | Sort-Object LocalPortornetstat -ano | findstr LISTENING - macOS:
lsof -nP -iTCP -sTCP:LISTEN - Linux:
ss -tlnp
If the port isn’t in the list, the program isn’t running or uses a different port. Fix that first; no router setting can help.
3. Test a port on another machine
- Windows:
Test-NetConnection 192.168.1.20 -Port 3389(look forTcpTestSucceeded : True) - macOS/Linux:
nc -vz 192.168.1.20 22
This works inside your network. It proves the device and its firewall are fine, so if the outside test still fails, the problem is the router or ISP.
Why a port stays closed from outside
- The router forward points at the wrong private IP (the device’s IP changed; reserve it in DHCP).
- The device’s firewall blocks the port. On Windows, add an inbound rule.
- Two routers (double NAT): the ISP router and your own router both need configuring, or put one in bridge mode.
- Your ISP uses CGNAT: if your router’s WAN IP differs from your public IP, forwarding cannot work until the ISP gives you a public or static IP.
- The ISP blocks the port. Many block 25 (email) and some block 80 on home lines.
Still stuck? Read port forwarding not working: the fixes.
Frequently asked questions
How do I know if port 80 or 443 is open?
Use an online port checker with your public IP and choose 80 or 443. Locally, run netstat -ano on Windows or lsof -iTCP -sTCP:LISTEN on macOS to see if a web server is listening.
Can I check if a port is open without software?
Yes. An online port checker tests from the internet with nothing to install, and Windows PowerShell has Test-NetConnection built in.
Why is my port open locally but closed online?
Usually the router isn’t forwarding it, there is double NAT, or your ISP uses CGNAT. Compare your router’s WAN IP with your public IP.
More guides
- What is IPv6?
- How to find your IP address (every device)
- Public vs private IP address
- What is CGNAT (carrier-grade NAT)?
- How to hide your IP address
- How to find your PS5 IP address
- How to find your Xbox IP address
- How to find your smart TV’s IP address
- How to find your router’s IP address
- What is a good internet speed?
- Why is my internet slow at night?
- How to change DNS on Windows 11 and 10
- How to change DNS on a Mac
- How to change DNS on your router
- Public DNS servers compared
- Why port forwarding isn’t working
- Keeping your internet on during load-shedding
- Fibre vs LTE vs 5G in South Africa
- How to create a strong password
- What is a user agent?
- How to find your MAC address
- What is a good ping?
- What is an IP address?