How to put a custom domain on a page

Everything about a published page can be rebuilt in an afternoon except the address people already have.

Hosting is a commodity. Move a page between services in an afternoon and nothing is lost. The address is the part that cannot be moved, unless it was yours to begin with.

Two DNS records at a registrar, pointing a domain and its www form at a host.
Two DNS records at a registrar, pointing a domain and its www form at a host.

This guide covers why it matters, the setup, and the two ways it goes wrong.

The address is what you cannot rebuild

Publish a link and it immediately spreads to places you cannot see.

Messages. Bookmarks. Other people's pages. Printed material. Search results. A profile you no longer maintain.

If that address is on a hosting provider's domain, all of it depends on that provider continuing to exist, to serve you, and to keep the same address scheme. When any of those changes, everything breaks at once and there is no recovery.

With your own domain, moving is a change of where the domain points. Every existing link keeps working.

This is why the domain is worth setting up before publishing an address, rather than after.

Revise the text click and type save Same document new version stored unchanged Same address nothing to resend
A revision changes the page, not the address that was already sent.

The setup

Two records at your registrar.

One for the bare domain, pointing at the host. One for the www version, pointing at the same place. The exact values come from whoever is hosting the page, and they publish them for this purpose.

That is usually the whole job. The interfaces differ, the concept does not.

Provider's address Your domain
Survives changing host No Yes
Survives the host closing No Yes
Appears in the browser bar Theirs Yours
Cost None Small, annual
Setup None Two records

Propagation is not a fault

After changing the records, the new destination takes effect over minutes to hours.

During that window some people reach the new place and some the old one, depending on what their network has cached. That is how the system works rather than something going wrong.

Do not change records repeatedly while waiting. Set them once, wait, then check.

Pick one form

Serve either the bare domain or the www version, and redirect the other to it.

Serving both means the same page exists at two addresses. Links split between them, search engines treat them as separate pages, and any counting you do is halved across two entries.

Which one you choose does not matter. Choosing is what matters, and then being consistent everywhere you write the address.

A www address redirecting to the bare domain form.
A www address redirecting to the bare domain form.

Renewal is the failure nobody plans for

A domain is rented annually. Miss the renewal and it expires.

After a grace period it becomes available to anyone, including people who register lapsed domains specifically because they still receive traffic. An address printed on your material can end up pointing at something you have no control over.

Turn on automatic renewal. Keep the payment method current. And keep the registrar login somewhere you will actually find it in two years, because it is the single account that everything else depends on.

For the surrounding ground, see Canonical URL: which address is the real one and Free HTML file hosting, compared.

Put it at an address

Register the domain before publishing the address, add the two records, pick one form and redirect the other, turn on automatic renewal, and keep the registrar details somewhere safe.

Then changing anything else about the page costs an afternoon rather than every link you have published.

Questions people ask

Why does the domain matter more than the hosting?

Because the page can be rebuilt and the address cannot. Once a link is in messages, other people's pages and search results, changing it breaks all of them at once.

What do I actually need to set up?

Usually two records at your domain registrar: one pointing the bare domain at the host, one pointing the www version at the same place. The host tells you the exact values.

How long does it take to work?

Usually minutes to a few hours, occasionally longer. During that window some people see the new destination and some see the old one, which is normal rather than a fault.

Should I use www or not?

Pick one, redirect the other to it, and never serve both. Two addresses showing the same page splits links and confuses search engines.

What happens if I stop paying for the domain?

It expires and can be registered by anyone, including someone who then controls an address printed on your material. Set it to renew automatically.

Keep reading