Differences between the DNS records
1 min readSep 12, 2019
A, CNAME records are all possible solutions to point a hostname to your site. However, they have small differences that affect how the client reaches your site.
Understanding the differences
These are the main differences:
The A record maps a name to one or more IP addresses when the IP are known and stable.
The CNAME record maps a name to another name. It should only be used when there are no other records on that name.
Which one to use
Understanding the difference between A name and CNAME records will help you decide.
General rules:
- Use an
Arecord if you manage which IP addresses are assigned to a particular machine, or if the IP are fixed (this is the most common case). - Use a
CNAMErecord if you want to alias one name to another name, and you don't need other records (such asMXrecords for emails) for the same name.
You should never use a CNAME record for your root domain name (e.g. example.com).
source: dnsimple
Originally published at https://abilng.in/blog/dns.html
