DNS Records Explained
DNS (Domain Name System) records are instructions that live in authoritative DNS servers and tell computers how to handle requests for your domain.
A Record
Maps a domain or subdomain to an IPv4 address.
yourdomain.com. IN A 123.456.789.0
Use this to point your domain directly to your hosting server's IP.
CNAME Record
Maps a subdomain to another domain name (an alias).
www.yourdomain.com. IN CNAME yourdomain.com.
Use this so www resolves to the same place as your root domain.
MX Record
Specifies the mail server responsible for receiving email for your domain.
yourdomain.com. IN MX 10 mail.yourdomain.com.
If you use cPanel email, your MX record should point to your hosting server. If you use Google Workspace or Microsoft 365, it will point to their servers.
TXT Record
Holds arbitrary text, commonly used for:
- SPF — authorises mail servers to send email on behalf of your domain
- DKIM — cryptographic email signature verification
- Domain verification — for Google Search Console, Facebook, etc.
yourdomain.com. IN TXT "v=spf1 include:yourmailserver.com ~all"
TTL (Time To Live)
TTL tells DNS resolvers how long (in seconds) to cache a record. Lower TTL = faster propagation when you make changes. A value of 3600 (1 hour) is standard.