Windows 11
Windows 11 can send DNS over HTTPS natively. It needs two things per server: an IP address to connect to, and the DoH URL (Windows calls it a template). The IP address only says where to connect; the template’s path is what selects your profile and device.
You need: your profile id and a device name. The server addresses are opdns’s shared addresses:
- IPv4:
23.166.164.53and23.166.164.35; - IPv6, if your network has it:
2602:81f:6000::53and2602:81f:6000::35.
-
Open Settings → Network & internet, then Wi-Fi or Ethernet, and the connection you use. For Wi-Fi choose Hardware properties.
-
Next to DNS server assignment, click Edit and choose Manual.
-
Turn on IPv4. In Preferred DNS, enter
23.166.164.53. -
Set DNS over HTTPS to On (manual template) and enter:
https://dns.opdns.net/<profile-id>/<device> -
Set Fallback to plaintext to Off. With it on, Windows silently uses unencrypted DNS when DoH fails, and those queries are not identified.
-
In Alternate DNS, enter
23.166.164.35, with the same DNS over HTTPS setting and template. -
If you have IPv6, turn on IPv6 and repeat with
2602:81f:6000::53(preferred) and2602:81f:6000::35(alternate) and the same template. -
Click Save, then check it works.
Repeat for each network adapter you use: the setting is per adapter.
Register the template once for each address, then point the adapter at them:
foreach ($server in "23.166.164.53", "23.166.164.35", "2602:81f:6000::53", "2602:81f:6000::35") { netsh dns add encryption server=$server ` dohtemplate=https://dns.opdns.net/<profile-id>/<device> ` autoupgrade=yes udpfallback=no}
Set-DnsClientServerAddress -InterfaceAlias "Wi-Fi" ` -ServerAddresses "23.166.164.53", "23.166.164.35", "2602:81f:6000::53", "2602:81f:6000::35"Check with netsh dns show encryption server=23.166.164.53.