Types of DNS Records Explained

7 Common Types of DNS Records – A, AAA, CNAME, NS Explained

Simplify Article With:
Share Article With: Link copied

The Domain Name System (DNS) has different types of records like A, TXT, CNAME, MX, NS, SOA, and more. There are different types of DNS records there some of which are common, while others are less commonly used.

In this article, we will see  what is a DNS records and common types of DNS records used for a website.

 

What is DNS Records?

DNS Records is simply a routing process to the servers from who request for accessing data into respective authorities servers through records stored. For example, you are searching a website in browser. In the hosting server there will be record called A record which has  details updated as 54.55.1.12. The browser check for the IP address that matches the website name which then will retrieve the website content from the respective server.

Similar to this, there are many other records which has their own purpose and data through which we can access different service which we use in our regular day to day life.

Field Description Example
Name (or Host) The domain name or hostname this record applies to www.example.com
TTL (Time-to-Live) How long (in seconds) a DNS resolver should cache the record before refreshing 3600 (1 hour)
Type The record type that defines what kind of information it contains A, AAAA, CNAME, MX, TXT, NS, SOA
Data/Value The actual data for this record type (IP address, hostname, text, etc.) 192.0.2.1 (for A record)

 

Common Types of DNS Record:

1. A Record:

As already said above, A records (aka) Address helps your map the website name with the IP address where the domain is hosted in the server.

This is one of the most important and commonly used DNS Records. This record points to the IP address of the domain. It lets you use easy-to-remember names, like www.example.com, instead of IP addresses like 51.81.0.71. This allows a user’s device to connect with and load a website.

Example – 51.81.0.71

 

2. AAAA Record:

AAAA records are next-generation internet addresses which contain domain names to an IPv6 address and helps you to resolve the void of limitation of number of ipv4 address. The AAAA records are the same as an A record, except they contain a alpha numeric values instead of just numbers like IPv4 address and length also varies for both.

Example –  2001:0db8:85a3:0000:0000:8a2e:0370:7334

 

3. CNAME Record: (Canonical Name Record)

A CNAME record is a kind of DNS records that connects an alias name to its real or official domain name. People usually use CNAME records to link a subdomain like www or mail to the main domain that has the content for that subdomain. For instance, a CNAME record can link the web address www.example.com to the actual website for example.com. It allows the user or the owner to access the both functions instead of just accessing the website with NS or A record.

Example – www. or blog. before the domain name.

 

4. MX Record: (Mail Exchange Record)

This DNS records help to find out which servers should receive mail for a specific domain. It’s important to set up these records so that you can send receive emails through the mail server. If you have a mail service with certain hosting provider, then you should get their MX records and update in your domain to point to their server for receiving emails.

Example:

Name Type ​Priority RDATA
@ MX 10 mx.email.com
@ MX 20 mx2.email.com

 

5. TXT Record:

TXT records hold details about your domain. They also provide important information that assists outside network servers and services in managing outgoing emails from your domain. You can use this to store text value of the domain or verify the domain ownership.

It is primarily used for email security (SPF, DKIM, DMARC) which helps to avoid email spoofing and phishing.

Example: 

Domain Ownership Verification – google-site-verification=xyz123abc

Sender Policy Framework – v=spf1 include:_spf.google.com ~all

DomainKeys Identified Mail – k=rsa; p=MIIBIjANBgkqhkiG9w0BAQ…

 

6. NS Record:

NS or Nameserver has both custom and private nameservers. This records are like the address book for your DNS zone because they tell which name servers responsible for managing it. To make sure your DNS setup works correctly, the NS records in your DNS zone need to match exactly with the name servers set up at your domain name provider.

Example – ns1.websitename.com and ns2.websitename.com or ns1.seekahost.net and ns2.seekahost.net

 

7. SOA Record:

SOA record also called Start of Authority which tells you who is the admin of the website you are looking for. The information contains email address of person responsible for manage domain, when the data should refresh and how other server should handle the website.

Serial: 2020080904
Mname: ns1.websitename.net
Retry: 1800
Refresh: 3600
Expire: 1209600
Rname: host.seekahost.in

 

Type Purpose Example Data
A Maps hostname to IPv4 address 192.0.2.1 cloudflare+1
AAAA Maps hostname to IPv6 address 2001:db8::1
CNAME Alias pointing to another domain name example.com
MX Mail server for the domain mail.example.com (priority 10)
TXT Text records (SPF, DKIM, verification) "v=spf1 include:_spf.google.com ~all"
NS Name server for the domain ns1.example.com
SOA Start of Authority (zone info) ns1.example.com admin.example.com

 

Why are DNS records important?

DNS serves as the connecting and bridge point of website to load the content and connect to the domain as well. In that, DNS records are most important for web hosting and keeping track of domain name. They contain all the information about stuff on the internet. As companies grow, it’s really important to manage their domain names, move things around, and handle email servers to keep their business running smoothly.

 

Explore Other Addon Resources:

1. IP Address of Server for Website Hosting Consist of

2. How The Domain Name System is Maintained

3. What does DNS Translates a Domain Name Into

 

Conclusion

DNS servers help connect a website’s name to its IP address using something called DNS records. Even though you don’t see it happening, these records are important for making sure a website or email server works properly.

There are different kinds of DNS records, and each one has its special job. Together, they make sure that websites stay up and running smoothly.

You also can find the DNS records for your domain by using third-party apps like leafdns.com and www.whatsmydns.net.