UniFi gateways do not accept a custom DNS-over-HTTPS or DNS-over-TLS
server with a path or a server name. For this reason, the gateway uses
plain DNS. On IPv6, it uses the profile’s own IPv6 address. On IPv4, it
uses the shared IPv4 addresses, and you
link your WAN address to the profile. A linked
IP is a public address that opdns maps to one profile.
In the dashboard, open the Setup page of the profile and link the IPv4
address of your network. If you are at home, click Link this
network. If your ISP changes your address, create a DDNS link instead.
See Linked IP.
In UniFi Network, open Settings → Internet and select the WAN. Set
DNS Server to manual, with 23.166.164.53 and 23.166.164.35. Under
IPv6, set the DNS server to the profile’s own IPv6 address from the
Setup page.
Screenshot to comeUniFi Network WAN settings with manual IPv4 and IPv6 DNS servers set to the opdns addresses.UniFi Network 9
In Settings → Networks, keep DHCP DNS Server on Auto (the
gateway) for each LAN. The clients then send their queries to the
gateway, and the gateway sends them to opdns.
The Dynamic DNS function of UniFi supports only the providers in its list.
Instead, run the DDNS update from a machine on the network that is always
on. The Linked IP
page shows how.
The connection between the gateway and opdns is not encrypted. opdns
gets no device names.
opdns identifies IPv4 queries only while the linked address is current.
opdns answers queries from an address that is not linked, but it does
not filter them.