Domains, DNS & Hosting
Domain names
A domain (example.com) is a human-friendly name for a server's IP address (93.184.216.34). You rent a domain yearly from a registrar (Namecheap, GoDaddy, Cloudflare).
DNS: the internet's phone book
When you visit a site, DNS turns the name into an IP:
browser cache → operating system → resolver (your ISP or 1.1.1.1) → root server → .com server → the domain's authoritative server → IP address.
Answers are cached for their TTL, which is why DNS changes can take a while to spread.
Common DNS records
| Record | Points to | Example use |
|---|---|---|
A | IPv4 address | main website |
AAAA | IPv6 address | main website (IPv6) |
CNAME | another domain | www → example.com |
MX | mail server | |
TXT | text | domain verification, SPF |
Hosting options
| Type | Good for | Examples |
|---|---|---|
| Static hosting | HTML/CSS/JS sites, React builds | GitHub Pages, Netlify, Vercel, Cloudflare Pages |
| Platform (PaaS) | Node, Python and other backends | Render, Railway, Fly.io |
| Backend-as-a-service | database, auth, storage | Supabase, Firebase |
| VPS / cloud servers | full control | DigitalOcean, AWS, GCP |
💡 Beginners: start with free static hosting plus Supabase for data.