[Solved] Difference between "Use custom DNS servers" and "DHCP-Options"

What is the difference between specifying a DNS server under "Interfaces > LAN > General Settings > Use custom DNS Servers" and "Interfaces > LAN > DHCP Server > Advanced Settings > DHCP-Options" ?


It seems like devices on my network will use the DNS server specified in either place.

The one in the interface settings is only for this specific interface and the other setting option is a global option.

Hence the global option in DHCP and DNS does allow to set a lot of other options apart from dns servers.

The former affects OpenWrt itself, the latter only DHCP clients.


Both of these fields are available under the interface settings. If I add a DNS server to DHCP-Options under the LAN interface, for example, this DNS server does not appear in the DHCP-Options of my LAN2 interface, so it doesn't seem to be global.

If I only set a DNS server in the "Use custom DNS servers" option, do I understand correctly that this server will be used both by OpenWrt and devices on my network? Whereas if I only specify a DNS server under DHCP-Options, non-static IP devices on my network will use this DNS and OpenWrt will will use some other DNS (ISP's DNS perhaps) ?

Correct. If you use a "Custom DNS server" then OpenWrt itself will use it as upstream while DHCP clients continue to use the OpenWrt DNS cache as server (which in turn queries the custom DNS server).

If you specify it as DHCP option, then you simply advertise a different DNS server to DHCP clients on this particular pool/interface but OpenWrt itself will use a different server (the ISP provided one most likely).

Good to know. Thanks!
Is there any typical/common reason one would want to have their router use a different DNS from the one used by devices on the network?

Parental filters or vpn specific dns.
This option can be per host.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.