How to set up DNS on Xiaomi router: from basic replacement to advanced schemes

Why setting up a DNS on a Xiaomi router is more important than you think

Domain name system (DNS) β€” It's like the Internet's phone book: it converts human addresses (like mi.com) into machine addresses. IP. But few people know that the standard DNS-ISPs from your ISP often work slowly, collect data about the sites visited, and can block access to certain resources. 4A flagship AX6000) replacement DNS permitting:

Speed up site loading by 20-40% by using the nearest servers (for example, 1.1.1.1 from Cloudflare or 8.8.8.8 from Google).

Bypass the blocking of Roskomnadzor or corporate restrictions without VPN.

β€” Protect yourself from phishing and malicious sites through DNS-filters (like 94.140.14.14 by AdGuard).

This article presents unique DNS configuration schemes for Xiaomi routers, taking into account MiWiFi firmware and alternative firmware (Padavan, OpenWRT), as well as solutions to typical problems such as β€œno settings are saved” or β€œDNS is not applied on connected devices”.

What are they? DNS-Servers to choose for Xiaomi-router in 2026

The choice of DNS depends on your purpose. Here is the current list of trusted servers with their features:

DNS-providerIPv4-addressIPv6-addressAdvantagesDeficiencies
Cloudflare1.1.1.1, 1.0.0.12606:4700:4700::1111Lowest latency, privacy (no logging IP)Sometimes it blocks legal torrents.
Google Public DNS8.8.8.8, 8.8.4.42001:4860:4860::8888High reliability, DoH supportCollects data for analytics
AdGuard DNS94.140.14.14, 94.140.15.152a10:50c0::ad1:ffBlock ads and trackers at the DNS levelIt can disrupt some websites.
Yandex DNS77.88.8.8, 77.88.8.12a02:6b8::feed:0ffOptimized for Runet, Family FilterSubject to the laws of the Russian Federation (censorship)

πŸ”Ή For maximum speed: use 1.1.1.1 (Cloudflare) + 8.8.4.4 (Google) as backup.

πŸ”Ή To block ads: 94.140.14.14 (AdGuard) + 76.76.19.19 (ControlD).

πŸ”Ή To bypass the locks: combine DNS doh (DNS over HTTPS) β€” We'll tell you about that below.

πŸ“Š What? DNS you're using it on the router?
Standard from the provider
Cloudflare (1.1.1.1)
Google (8.8.8.8)
AdGuard (for blocking ads)
Other

Step-by-step: how to change the DNS on the Xiaomi router

The configuration process depends on the firmware of your router, and let’s consider two scenarios: official MiWiFi and custom firmware (Padavan/OpenWRT).

Method 1: Official MiWiFi firmware (for most users)

1. Connect to your router via Wi-Fi or cable. Open your browser and type in 192.168.31.1 (or miwifi.com). Sign in with your Xiaomi account.

2. Go to the section Additional settings β†’ Network β†’ LAN settings.

3. In the field "Primary DNS" enter the first address (for example, 1.1.1.1), in the field "Alternative DNS" - the second (for example, 8.8.8.8).

4. Press Save and restart the router through System Tools β†’ Reboot.

Ping to the new DNS is lossless (in command line: ping 1.1.1.1)

Websites open faster (check on DNSPerf)

The setting is saved after the router restarts

Devices on the network use new DNS (check out the DNS Leak Test)

-->

Method 2: Castom firmware (Padavan/OpenWRT)

Alternative firmware is more complex, but more flexible.

  1. Go to the web interface (usually 192.168.1.1).
  2. Go to the LAN β†’ DHCP Server.
  3. In the β€œDNS Server” field, specify the desired addresses by comma: 1.1.1.1,8.8.8.8.
  4. Enable the "Use user-specified DNS" option and save the settings.

πŸ”§ OpenWRT will require file editing /etc/config/dhcp through SSH. Add a line:

list dhcp_option '6,1.1.1.1,8.8.8.8'

πŸ’‘

If some sites have stopped opening after the DNS change, try using DNS-over-HTTPS (DoH) through services like NextDNS or Control D. This bypasses ISP-level blocking.

Advanced schemes: DNS-over-HTTPS (DoH) and DNS-over-TLS (DoT) on Xiaomi

The usual DNS replacement does not protect your requests from being eavesdropped by the provider.

  • πŸ”’ DNS-over-HTTPS (DoH): Encrypts requests via HTTPS. Supported by Mi Router AX6000 newer.
  • πŸ›‘οΈ DNS-over-TLS (DoT): uses a separate encrypted channel (port 853.

πŸ”Ή How to set up DoH on Xiaomi AX6000:

  1. Go to the Additional settings β†’ Network β†’ DNS.
  2. Enable the option "Use DNS-over-HTTPS".
  3. Select a provider (Cloudflare, Google) or enter your URL (e.g. https://dns.google/dns-query).

⚠️ Note: Routers with firmware older than MiWiFi R3G (2021) DoH may not work. In this case, use DoT through the terminal:

uci set dhcp.@dnsmasq[0].server='tls://1.1.1.1'


uci commit




/etc/init.d/dnsmasq restart

Typical problems and their solutions

Even after you set up your DNS properly, you can have a failure, and here are the most common cases and ways to fix them:

⚠️ Attention: If after the shift DNS You can't open any of the websites of banks or government services, return the standard settings of the provider. DNS (8.8.8.8 may not work with Sberbank Online).

Problem.Reason.Decision
DNS is not applicable to connected devicesDevices ignore router DNS and use their own (Android/iOS)Turn off β€œPrivate DNS” on Android or β€œLimit IP Tracking” on iPhone
DNS settings reset after rebootingMiWiFi firmware bug (especially on Mi Router 3/3G)Update your firmware or install Padavan
Slow Internet operation after the DNS changeSelected DNS-servers are geographicallyCheck the delay via nslookup or DNS Benchmark

πŸ”§ If nothing helps:

  1. Reset the router to factory settings (reset button for 10 seconds).
  2. Check if your provider is blocking the change in DNS (relevant for Rostelecom and Beeline).
  3. Install an alternative firmware (e.g., Padavan for Mi Router 4A).
How to check which DNS your device is using?
Open the command line (Windows: Win) + R β†’ cmd, macOS/Linux: Terminal) and type: nslookup ya.ru In response will be the Server line: {IP-address, this is your current address. DNS-server.

Let’s say you want kids to use a family-filtered DNS (like Yandex DNS Safe) and your work laptop to use it without restrictions. On Xiaomi routers, you can do this in two ways:

Method 1: Through the binding MAC-address (only) Padavan/OpenWRT)

1. Find it. MAC-device addresses in the section DHCP β†’ Clients.

2.In /etc/dnsmasq.conf add the rules:

dhcp-host=AA:BB:CC:11:22:33,set:kids


dhcp-option=tag:kids,6,77.88.8.2  # Yandex Safe DNS




dhcp-option=tag:!kids,6,1.1.1.1 #Cloudflare

Method 2: VLAN (for advanced users)

Create a separate network (VLAN) for devices with special DNS rules.

  • πŸ”§ Router with support VLAN (for example, Xiaomi AX9000).
  • πŸ“‘ Settings on the switch (if used).
  • πŸ–₯️ Separate. DHCP-server-by-server VLAN.

⚠️ Attention: Incorrect setting VLAN This may result in loss of access to the router.Before experimenting, back up the configuration through System Tools. β†’ Backup.

Security: How to Protect DNS Settings from Changes

If other people have access to your router (such as in an office or dorm), they can reset their DNS to standard.

  • πŸ” Change the password of the admin panel to a complex one (at least 12 characters, with numbers and special characters).
  • πŸ›‘οΈ Disable Remote Access to System Tools β†’ Remote control.
  • πŸ”’ Create a guest network with separate settings DNS (wifi β†’ Guest network).
  • πŸ“œ Export the configuration after setting up and store it in a safe place.

πŸ”§ For maximum protection on firmware Padavan can disable the web interface and manage the router only through SSH:

uci set uhttpd.main.enable='0'


uci commit




/etc/init.d/uhttpd stop

πŸ’‘

Using public DNSs (like Cloudflare or Google) doesn’t make you completely anonymous. For real privacy, combine DNS with VPN or Tor.

FAQ: Frequent questions about setting up DNS on Xiaomi

Can I use a DNS from a provider and a public DNS at the same time?
Yes, but that doesn't make sense. The router will only send requests to the first DNS specified, and the alternative will only be used when it is not available. You'd better choose one reliable option (e.g., 1.1.1.1) and one backup option (8.8.8.8).
Why do some websites open more slowly after the DNS change?
It's caching-related. DNS. Clear the cache on the device: πŸͺŸ Windows: ipconfig /flushdns command-line. πŸ“± Android: Reboot your device or use apps like DNS Changer. 🍎 macOS/iOS: Turn off/on Wi-Fi.
How to configure DNS for IPTV on Xiaomi router?
For a stable job. IPTV (For example, Rostelecom TV or MTS TV use DNS provider: πŸ“Ί Rostelecom: 46.32.231.2, 77.88.8.8. πŸ“‘ MTS: 217.29.160.160, 217.29.160.161. Add them to Settings LAN β†’ DNS and enable the option "Priority for IPTV" (if).
Can you use DNS-over-HTTPS on older Xiaomi models (e.g. Mi Router 3)?
No, the official MiWiFi firmware for older models does not support DoH. Solutions: Install Padavan or OpenWRT. Set up DoH at the device level (for example, in the Firefox browser or via NextDNS on Android).
How do you know if the new DNS is working?
Use these services: 🌍 DNS Leak Test - will show the current DNS-server. ⏱️ GRC DNS Benchmark - Testing the speed. πŸ” Cloudflare Test – Check if you are using them DNS.