Access internally hosted website from inside LAN using FQDN (NAT loopback?)


I'm trying to connect to my domain name "" from inside the LAN but it fails. But it works fine if i'm not connected to the LAN.

For example:

  1. my external IP is
  2. my domain name resolves to this ip address.
  3. Inside the LAN the webserver is at port 8080
  4. I have a port forward for anything coming in the WAN on port 80 ->

When i access from my cell phone with wifi turned off it works fine.

When i enable wifi on the cell phone and i'm connected to the LAN and i attempt to connect to domain it times out.

What is the best way to resolve this?

It worked on the stock netgear firmware.


i guess you should try to use or LAN-IP:8080 when accessing from the LAN side ?

that gives me a connection refused error.

Rebind the domain name to the server LAN IP:
And make sure to specify its LAN port in the URL.

1 Like

Unfortunately i still get a connection refused. Here is what was added to /etc/config/dhcp

config domain
        option ip ''
        option name ''

And from browser i tried to access:

1 Like

Verify that your LAN IP range is not filtered in the web server config.

It's not i can access it directly at (although it brings me to the root website since it's missing the domain name header)

Each site in httpd typically has a separate config which can use a different set of allowed IPs.

did you restart dnsmasq afterwards ?

1 Like

I'm actually using nginx inside a docker container on a different server not httpd.

Yes i restarted dnsmasq, but I have dns setup to use google DNS.

I since the hostname is resolving to the external IP, I guess the real problem is how to use external IP address from inside the network.

set a rule on the outgoing traffic, to redirect to, or change the DNS.

1 Like

So in Luci, under interfaces->devices -> "br-lan" device, when i check the box for "promiscuous mode" then it works.

Is there any downsides to enabling promiscuous mode on the br-lan?