Set Up Dynamic DNS (DDNS)
Run a Speed TestMost home internet connections use a dynamic public IP address that changes periodically — making it impossible to reliably reach your home network by IP. Dynamic DNS solves this by mapping a fixed hostname to your current IP and automatically updating the record whenever it changes.
Why You Need DDNS
When you want to access your home NAS, security cameras, self-hosted server, or VPN from outside your network, you need to know your home's current public IP address. ISPs assign dynamic IPs that can change daily or weekly. DDNS keeps a DNS record pointing to your current IP, updated automatically, so you always connect via a stable hostname like yourhome.duckdns.org.
DDNS works alongside port forwarding — DDNS resolves the hostname to your IP, and port forwarding directs the traffic from that IP to the right device on your local network.
Check for CGNAT First
Before setting up DDNS, verify you have a publicly routable IP address. Some ISPs — particularly mobile carriers and some cable providers — use CGNAT (Carrier-Grade NAT), which means your router's WAN IP is a private address shared with many other customers. DDNS cannot work through CGNAT because you have no control over the outer IP.
Check your router's WAN IP in the admin panel under Status or WAN. If it starts with 100.64–100.127, 10.x, 172.16–31.x, or 192.168.x, you are behind CGNAT. Contact your ISP to request a dedicated public IP, or use Tailscale or ZeroTier, which create peer-to-peer tunnels that do not require a publicly routable IP.
Step 1: Choose a DDNS Provider
Several free and paid providers are well-supported in home routers:
- Duck DNS — fully free, subdomains under duckdns.org, update via simple URL or Docker container
- No-IP — free tier with one hostname, requires account confirmation every 30 days; paid tier removes the restriction
- Cloudflare — free if you own a domain registered with or transferred to Cloudflare; use the API to update your own A record
- Afraid.org (FreeDNS) — free with subdomains on shared domains; reliable for low-traffic personal use
Duck DNS is the simplest starting point for most home users who do not own a domain. Cloudflare is the best choice if you want a clean hostname on a domain you own.
Step 2: Create Your Hostname
Register at your chosen provider and create a hostname. For Duck DNS, log in with a Google or GitHub account, type a subdomain name, and click Add Domain. Your hostname will be yourname.duckdns.org. Note your token — you will need it for router configuration.
Step 3: Configure DDNS on Your Router
Most modern routers have built-in DDNS clients. The location varies by brand:
- ASUS: WAN → DDNS
- TP-Link: Dynamic DNS under Advanced → Network
- Netgear: Advanced → Advanced Setup → Dynamic DNS
- Ubiquiti UniFi: Settings → Internet → Dynamic DNS
Select your provider from the dropdown, enter your hostname, username, and password or token. Save and apply. The router will immediately register your current IP and continue updating automatically.
Step 4: Test
From a device on mobile data (not your home Wi-Fi), run ping yourname.duckdns.org. The IP in the response should match your home's current public WAN IP shown in your router's admin panel. If they match, DDNS is working correctly.
Using Cloudflare for a Custom Domain
If you own a domain, point its nameservers to Cloudflare (free plan), then use a DDNS client like ddclient or inadyn running on a Raspberry Pi or NAS to update an A record via the Cloudflare API. This gives you a clean hostname like home.yourdomain.com with no third-party subdomain. Set the Cloudflare proxy to DNS-only (grey cloud) for direct IP resolution.
| Provider | Free Tier | Update Interval | Custom Domain | Router Built-in Support |
|---|---|---|---|---|
| Duck DNS | Yes, unlimited | <60 seconds | No (duckdns.org subdomains) | Some routers via URL method |
| No-IP | 1 hostname, confirm every 30 days | 1–5 minutes | No | Most major brands |
| Cloudflare | Yes (own domain required) | Via ddclient/inadyn | Yes | Some via API client |
| Afraid.org | Yes, shared subdomains | ~5 minutes | No | Limited |
| DynDNS | No (paid only) | 1–5 minutes | Yes | Most major brands |