Chapter 09 of 09Part 3 · Quality and launch
How to launch a website on your own domain
Domains, hosting, DNS records and HTTPS, then the titles, sitemap and Search Console that help people find your page.
9 minBy Zuzo StudioUpdated
In this chapter you will
- buy a domain and connect it to a host with DNS records
- check that HTTPS is on and every page has one address
- add titles, a sitemap and Search Console before you share the link
Before you startThis builds on Website speed and Core Web Vitals explained.
Your page works on your own computer. To put it in front of anyone else you need four things: an address people can type, a server that hands out your files, a secure connection, and a way to tell search engines the page exists. That is all "how to launch a website" really means, and for a small static site none of it needs to cost much or take long. This chapter goes through each piece in the order you will set them up, then finishes the course project by putting your page live.
01Domain names: renting your address
A domain name like example.com is the human friendly address that DNS turns into a server's IP address, the step we saw in the first chapter. You buy one from a registrar, a company accredited to sell names in a given ending such as .com or .studio.
As MDN's explainer on what a domain name is points out, you never own a domain. You rent the right to use it for a period, usually a year at a time, and you keep it for as long as you renew. Let it lapse and someone else can register it.
A few things to settle before you pay:
- Pick a short name you can say out loud. If you have to spell it twice on the phone, it is too clever.
- Check the renewal price, not just the first year. Introductory prices are common, and some endings cost far more to renew.
- Turn on auto renew and keep the account email current. Losing a domain to an expired card is a painful and common way for a site to disappear.
- Register it in your own name. If an agency or a friend buys it for you, make sure the account is yours.
02Hosting: somewhere for your files to live
Hosting is a computer that is always on and answers requests for your files. Your project is static: plain HTML, CSS, a little JavaScript and some images, the same for every visitor. Static sites are the easiest kind to host. Services such as GitHub Pages, Netlify or Cloudflare Pages will serve one from a global network of servers, often on a free plan.
The usual setup is one of two:
- Drag and drop. Upload your project folder in the host's dashboard and it is live at a temporary address.
- Connect a Git repository. Push your code to GitHub or GitLab, and the host publishes a new version every time you push. This is how most teams work, because every change is recorded and easy to undo.
Either way you get a free address on the host's own domain first, something like your-site.pages.dev. Check that everything works there before you connect your own domain.
03DNS records: pointing the domain at the host
Buying a domain and renting hosting are two separate things. DNS records are what join them. They live in a zone file at your DNS provider, which is usually your registrar unless you move it, and each record is a small instruction.
| Record | What it does | Example value |
|---|---|---|
| A | Points a name at an IPv4 address | 192.0.2.10 |
| AAAA | Points a name at an IPv6 address | 2001:db8::10 |
| CNAME | Points a name at another name | your-site.pages.dev |
| MX | Says which server receives email for the domain | mail.example.net |
| TXT | Holds text, often to prove you own the domain | google-site-verification=... |
Your host will tell you exactly what to add. A common pattern is an A or CNAME record for the bare domain, example.com, and a CNAME for www pointing at the host. Pick one of the two as the main address and have the other redirect to it, so each page lives at one URL only.
Every record also has a TTL, time to live, which tells other DNS servers how long they may cache the answer. Changes can take a while to reach everyone because old answers are still cached, which is why a new domain sometimes works on your phone before your laptop.
04HTTPS: the padlock
HTTPS encrypts the connection between the browser and your server using TLS, so nobody on the same wifi can read or change what is sent. Browsers mark plain HTTP pages as not secure, and features such as geolocation and service workers only work over HTTPS. There is no reason to launch without it.
To use HTTPS your server needs a certificate, a file that proves it really serves your domain. Let's Encrypt is a free, automated certificate authority run by a nonprofit. It uses a protocol called ACME: software on the server proves it controls the domain, receives a certificate and renews it automatically before it expires.
Most static hosts do all of this for you. Once your DNS records point at them, they issue the certificate within minutes. Your two jobs are to check that https:// loads without a warning, and to turn on the setting that redirects every http:// request to https://.
05How to launch a website people can find
A live page is not the same as a found page. Before you tell anyone about it, do the small things that help search engines understand it.
Title and description
Every page needs a unique <title>, which becomes the clickable headline in search results, and a meta description, which search engines often use for the snippet below it. Write them for people, not for keywords.
<title>Northlight Studio: brand websites in Leeds</title>
<meta name="description" content="A small design studio building fast, accessible websites for independent brands.">
<link rel="canonical" href="https://example.com/">
The canonical link tells search engines which URL is the main one, which matters once both www and the bare domain work.
Sitemap and robots.txt
A sitemap is an XML file that lists the URLs you want crawled. Google's guide to building a sitemap sets a limit of 50,000 URLs or 50MB per file, which a small site will never reach. A robots.txt file at the root tells crawlers what they may visit and where the sitemap is.
User-agent: *
Allow: /
Sitemap: https://example.com/sitemap.xml
Search Console
Google Search Console shows which searches bring people to your site, which pages are indexed and, once you have traffic, your Core Web Vitals from the previous chapter. Google's getting started guide starts with verifying that you own the site, which for a whole domain means adding a TXT record to your DNS, then submitting your sitemap.
Analytics, with consent
Analytics tells you how many people visit and what they do. Privacy rules in many places, including the UK and the EU, expect a visitor's consent before a site sets cookies it does not strictly need, and analytics cookies usually fall into that group. If you use Google Analytics, consent mode lets your banner tell Google's tags whether the visitor said yes, and the tags only store analytics cookies once they have. Simpler, cookie free analytics tools exist too, and for a one-page site they may be all you need.
06After launch
Launch day is the start, not the finish. Check the site on a real phone, click every link, send yourself a message through the contact link, and look at Search Console again after a week. Sites need looking after: domains and plans renew, content goes stale, and new tags creep in. Our website maintenance checklist lists what to check and how often, and if you ever move an existing site to a new address, the website migration SEO checklist covers the redirects that keep its rankings.
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url><loc>https://example.com/</loc></url>
</urlset>
That is the course. You have gone from typing an address to owning one, and you understand each layer in between. If you want to keep going, the Core Web Vitals checklist and the accessibility checklist are good next reads.
Check your understanding
3 questions
Key takeaways
- You rent a domain from a registrar rather than own it, so keep auto renew on and the account in your own name.
- DNS records join the domain to the host: A and AAAA point at addresses, CNAME at another name, MX and TXT often belong to your email.
- Most static hosts issue a free HTTPS certificate automatically once your DNS points at them.
- Give every page a unique title and description, list your URLs in a sitemap and submit it in Search Console.
- Only set analytics cookies once the visitor has agreed to them.
Sources
- What is a domain name?MDN Web Docs, checked
- How It WorksLet's Encrypt, checked
- Build and submit a sitemapGoogle Search Central, checked
- Get started with Search ConsoleGoogle Search Central, checked
- Set up consent mode on websitesGoogle for Developers, checked