← Posts

Hosting a personal site without moving your DNS

The annoying part of static hosting is never the HTML. It is deciding who answers DNS for your domain, and who is allowed to issue the certificate.

A CNAME is illegal at a zone apex, because it cannot coexist with other records and the apex must carry SOA and NS. So hosts either hand you fixed anycast IPs, or you need a registrar that supports ALIAS, which resolves the target at query time and returns an address record. That distinction matters if the apex also carries MX records: ALIAS sits beside them, a CNAME would wipe them out.

Which is the whole trick. Point the apex at your host with an ALIAS, leave the MX records alone, and email keeps working at the registrar while the website is served somewhere else.