Qvantor logo QvantorInfrastructure, explained plainly
Self Hosting

Dynamic DNS Setup to Reach Your Home Server by Name

The server at home is fine. The router is fine. What broke is the sentence you memorised two months ago, the one with four numbers in it, because your provider handed your line a different address at some point on Tuesday and never...

A mini PC home server beside a router with a laptop showing a DNS record edit screen and a terminal log

The server at home is fine. The router is fine. What broke is the sentence you memorised two months ago, the one with four numbers in it, because your provider handed your line a different address at some point on Tuesday and never mentioned it. You find this out in an airport, where the photo backup app spins and times out and the VPN client reports that it cannot reach a host that no longer exists under that name.

Dynamic DNS is the small piece of plumbing that fixes this, and it takes about twenty minutes. The part people get wrong is not the setup. It is the credential they hand to the thing doing the updating, which on a lot of home routers is a password with full control of every record in a domain, stored in a config file you cannot read and backed up in plain text to whatever cloud the vendor uses. I have audited that exact arrangement at two small companies. Both times the domain was worth more than the server.

Why the address changes, and when it does not

Residential lines almost always get an address on a lease rather than a permanent assignment. The lease renews quietly and usually renews with the same address, which is why plenty of people run for a year on a hardcoded number and conclude that the problem is imaginary. Then the router reboots after a firmware update, or the line drops for ninety seconds during overnight maintenance, and the renewal comes back with something new.

Three events account for nearly every change I have logged on my own line over four years: a power cut, a firmware update that reboots the modem, and provider maintenance in the small hours. Eleven changes in total, nine of them between two and five in the morning, which is exactly when you are least likely to notice and most likely to have a backup job running.

Before you set anything up, find out whether a public address reaches you at all. Open your router status page and read the address on the wide area network interface. Then check what the internet thinks your address is from a device on the same network. If the router shows something starting with 100.64 through 100.127, or a private 10 or 192.168 address, you sit behind carrier grade translation and no amount of DNS will help. Your provider is sharing one public address across many customers, and inbound connections do not have a path to you. In that case your options are a business line with a static address, an extra charge for a public address if the provider offers one, or an outbound tunnel. Nothing else works, and I have watched people spend a weekend on records before checking this.

Three ways to keep a name pointed at home

All three do the same job. They differ in who holds the credential and how much you care about the name itself.

ApproachWhat you getCostMain drawback
Free provider subdomainA name under someone else's domainFree, with a monthly confirmation click on some plansThe shared parent domain can land on blocklists because of other users
Your own domain, updated by a client on the serverFull control, any subdomain you likeAround 10 to 15 per year for the domainYou have to scope the token yourself
Outbound tunnel or mesh VPNReachability with no inbound ports at allFree tier covers a householdA third party sits in the path, and it is the only option under carrier grade translation

I run the second one. A domain I already own, one subdomain for the server, a small client on the server that checks its own address every five minutes and updates the record when it differs. The client is the boring part. The token is the part worth thinking about.

The router DDNS field is the wrong place for this

Every consumer router has a dynamic DNS page, and the standard advice is to fill it in because the router already knows its own address and needs no helper software. The logic is sound and I still tell people not to do it.

Older firmware tends to support authentication styles that predate scoped tokens, which in practice means it wants the global key for your DNS account. That key can edit every record in every domain you own, create new ones, and in some cases change nameservers. A router is a device you do not patch often, whose configuration you cannot inspect, and whose backup file is frequently an unencrypted archive. Putting an account wide credential in there to save installing one package is a poor trade.

Run the updater on the server instead, with a token that can do exactly one thing. On Cloudflare that means a custom token limited to zone DNS edit permission on a single zone, which you can further pin to a source address range. On other providers look for the words scoped, restricted, or per record. If the only credential on offer is the account password, that provider is not where your domain should live. The same reasoning drives the rest of the checklist before exposing a home server online, and this is the step people skip.

A second habit worth keeping: give the updater its own token, note what it is for in the token description, and write the creation date next to it. When you eventually find a token in a config file eighteen months from now, you want to know in five seconds whether it is safe to revoke.

What the updater actually does

The mechanics are modest. A small daemon such as ddclient or inadyn runs on the server, asks an external service what your current public address is, compares that answer with a cached value, and calls your DNS provider's API only when the two differ. On a stable line that means it makes one request every five minutes to a lookup service and touches your DNS provider roughly once a quarter.

Two details matter more than the choice of client. The first is the record time to live. Set it to 300 seconds, or 60 if your provider allows it. A record with a day long time to live will keep sending people to an address you no longer hold for most of a day after a change, which defeats the whole arrangement. The second is where the client asks for its address. If it asks the router over the local network it can read a translated address and update your record with something private, which fails silently. Point it at an external lookup and read the log once to confirm the value looks like a public address.

Give it a health check as well. My updater writes a line to its log on every run, and a monitor flags me if that file stops changing for an hour. The failure mode worth catching is not a wrong address, which is loud. It is an expired token, which is quiet, and which you discover at the airport again.

A name is not a security boundary

Once the name resolves, treat it as public. A subdomain on a real domain gets picked up by certificate transparency logs the moment you request a certificate for it, and scanners read those logs continuously. Choosing an obscure label does nothing. I have seen a fresh subdomain take its first unsolicited login attempt inside fourteen minutes of a certificate going live.

So the name gets you reachability, nothing else. What stands between that name and your data is the usual set: no administrative interface published to the open internet, key based login only, a firewall that allows the two ports you meant to allow, and for anything genuinely private, access over WireGuard for remote access to a home server rather than a published port. Several of the services covered across our self hosting notes are safer with no public port at all, reached only through the tunnel, with dynamic DNS doing nothing more than telling the tunnel where home is this week.

FAQ

Do I need a static IP for a home server?

No, unless you are behind carrier grade translation or running a mail server. For everything else a dynamic address plus a name updated every few minutes behaves the same in daily use.

How do I know if I am behind CGNAT?

Compare the address on your router's wide area interface with the address the internet reports for you. If they differ, or the router shows something in the 100.64 to 100.127 range, inbound connections cannot reach you directly.

Is a free dynamic DNS subdomain good enough?

For a VPN endpoint or a personal dashboard, usually yes. Avoid it for anything that sends mail or needs a reputation, because you inherit whatever the shared parent domain has collected from other users.

How often should the updater check?

Every five minutes is plenty and stays well inside the rate limits of every lookup service I have used. Keep the record time to live at 300 seconds or lower so clients pick up a change quickly.

ON
Obi Nwachukwu

Obi works on account security and explains phishing, passwords and access in plain terms.

More posts by Obi

More in Self Hosting

01doorganico 084goad 3hot8 4465456 after5internprogram ahandfulofblessings ahmadpc ahomcybersecurity allodialresources annodex antiquesandperiodcollectibles aotc asianworldkashmir beedlectrics bloggertemplatefree bluefeatheragency bodyweightsolution campaign08blog carfixadvisor catstreetcollective cbstvsports cnfanspurchasing committeeof500yearsofdignityandresistance covertopsdjs cs-kaiyuangame cuestacomunicaciontotal cxoutlet dancebetgame deskgearhub destinyvillastay detectmagazine di33 diamondsteelbuildings donmo dyanadropship emarsysfinance emimattl escapechan eskitarih evautoplay everythingweddings-orlando farmzone feedviewerapp foxstudiosscratch gamevui123 gleasongrade greetingsday hacklabasu haskell iw-kaiyun jagoanproperti jilidskripsi joltbusinessfinance juegodepokergratis juegospucca kaeru-festival latestmehndidesigns lestanzediottaviano litemagazines localcommunityhero lustrsazan mariashebets menswheels newwebstechs1 nikkit ootheday oxigenvpn plurfitness prefetial probudgetcarpetcleaning psychicmrsmartin pyaten rejoignezlogis rexzbot riselayouts ruchin rwxqsgd5 sakaltime shibiaowang shop-bot skrtips spotlesshaven strcoding tetapatrium topselller uneplanteartificielle vipertechcr webtech1223411 wo-kygaming yamaha-mekar yeknava yoybuysheets zenunwa yamaha-mekar jilidskripsi ankertoto ankertoto ankertoto