Skip to content

Confirming Public IP Before a Port-Forward Test

TL;DR / Summary: Port-forward tests fail for boring reasons: you probed the wrong public IP, you tested from inside the LAN, or CGNAT made the forward unreachable from the outside. Confirm the current egress address, test from a true external network, and interpret “connection refused” differently from “timeout.”

Know which address the internet will dial

Your port-forward rule points an external port at an internal host. Outside clients must aim at your current public IP—or a hostname that resolves to it—not at the router’s LAN address.

Write down the public IP immediately before the test. Leases change; a hostname that updated an hour ago may still be wrong if DNS is cached on the probing machine.

If you use both IPv4 and IPv6, know which family the forward applies to. An IPv6-only listener will not answer an IPv4 probe.

Inside-LAN tests lie

Hairpin NAT (NAT loopback) is inconsistent across routers. Testing a public IP from a laptop on the same LAN may fail even when external users would succeed—or succeed when external users would fail.

Use a phone on cellular data, a VPS, or a friend’s network for the external probe. That is the only trustworthy outside view.

What to record during the probe

  • public IP you targeted
  • port and protocol (TCP/UDP)
  • network used for the probe (cellular, remote VPS)
  • result: connect, refuse, or timeout

Those four fields turn a vague “it doesn’t work” into a diagnosable report.

Confirm the target IP with What Is My IP Address Inquire on a machine behind the router you are forwarding through—right before you start the external probe.

Read the failure mode

Connection refused often means something answered on that IP—usually your router—and no service is listening on the port, or a firewall actively rejects it.

Timeouts more often mean drops: ISP blocks, missing forward, wrong internal IP, or CGNAT where your “public” address is not uniquely yours.

Refuse and timeout point at different layers. Do not treat them as synonyms.

Wrong internal IP (stale DHCP) produces outside timeouts while the service works on the LAN. Check the host’s current address against the forward rule.

CGNAT changes the meaning of “public IP”

Under carrier-grade NAT, the address you see may be shared, and inbound forwards on your home router never receive unsolicited internet traffic. No amount of port-forward configuration on your LAN gear fixes that.

Clues include ISP documentation mentioning CGNAT, failure of all inbound tests despite correct rules, and inability to ping your looked-up address from outside.

Remedies are product-level: request a public IP, upgrade tiers, or use outbound tunnels/relays instead of classic forwards.

Double-NAT with ISP gateways

When an ISP modem runs NAT and you add your own router behind it, you have two layers. Forwarding only on the inner router is not enough; the outer gateway must forward to the inner router’s WAN address, which must itself be reachable.

Prefer bridge/passthrough mode on the ISP gateway when you want a single NAT boundary. Document which device holds the true public IP.

Quick double-NAT check

  • compare the public IP lookup to the WAN IP shown on your inner router
  • if they differ, another NAT sits in front
  • fix the outer device’s client list for your router’s address

Matching WAN IP to the lookup is the green light for single-layer forwards.

Security while you test

Open only the ports you need, and only while testing if possible. Forwarding admin interfaces to the world is a common self-own.

Prefer keys over passwords on forwarded SSH, and keep services patched. A successful forward test is also a successful attack path if left careless.

Prove reachability, then harden exposure.

Close temporary test forwards when you finish. Forgotten rules accumulate.

UDP services need different probes

Game servers, WireGuard, and some VoIP paths use UDP. A TCP port check against a UDP-only forward will mislead you into thinking the forward is broken.

Use a probe that speaks the same protocol, or temporarily run a known UDP echo tool on the internal host while you test. Match protocol in the router rule and in the test.

Firewalls sometimes allow TCP established flows while dropping unsolicited UDP. If TCP forwards work and UDP fails, inspect UDP-specific filters before rewriting the entire NAT setup.

Also confirm the internal host’s local firewall allows the inbound port on the LAN interface. A perfect router forward still fails if the PC silently drops the packet.

Dynamic DNS and retests

After a modem reboot, re-check the public IP before blaming the application. Update DDNS, flush resolver caches on the probe machine, and run the external test again.

Automate DDNS where you can so overnight lease changes do not silently break inbound access.

Schedule a monthly external probe if the forward matters for work. Quiet lease changes are easier to catch on a calendar than during an emergency.

Port forwarding is a chain: public identity, NAT layers, correct internal host, listening service, and an honest external probe. Start with the public IP, or every later step is theatre.

Carrier-grade NAT still fools DIY forwards

If the address on the modem WAN page is private (often 10.x or 100.64.x) while a public lookup shows a shared carrier IP, your forward will never accept inbound traffic from the wider internet.

Ask the ISP for a public WAN address or a business package before you rebuild firewall rules. No amount of router tinkering unlocks inbound ports behind CGNAT.