DNS Record Types

TL;DR
DNS (Domain Name System) translates human-readable domain names into IP addresses so computers can locate servers.
DNS Record Types
NS records say who is in charge of a domain’s DNS (which name servers hold the answers).
A records map a domain to an IPv4 address (exact server location).
AAAA records do the same for IPv6 addresses.
CNAME records create aliases, pointing one domain name to another (e.g.,
www.google.com→google.com).MX records tell the internet where to deliver emails and in what priority.
TXT records store verification and security rules (SPF, DKIM, DMARC).
All DNS records work together so websites load correctly, emails arrive, and security checks pass.
Have you ever wondered how typing a website name like google.com takes you to the right place in seconds? This simple action is powered by something called DNS records. DNS records are like instructions for the internet, telling it where websites are hosted, how emails should be delivered, and which servers handle different services. Before DNS records, managing these connections was slow and manual. Today, they quietly work behind the scenes, making the internet fast, reliable, and easy to use. Understanding DNS records is an important step in learning how the internet really works.
What is DNS?
Domain Name System(DNS)
DNS is the internet's phonebook. It translates human-readable website names into numerical, machine-readable IP addresses (like 192.168.1.1) that computers use to communicate over the internet. When you type a web address like www.facebook.com into your browser, DNS finds the matching IP address so your device can connect to the correct server. In simpler terms, you can think of DNS as asking, “Whom to talk to next?”
Why are DNS records needed?
DNS records are needed because they tell the internet how to find and handle your domain. Without DNS records, a domain name would be just a label with no direction on where to go or what to do.
It:
Convert domain names to IP addresses
Route traffic to the correct services
Enable email delivery
Support load balancing & high availability
Improve security
In short, DNS records are needed to connect domain names to real internet services securely, reliably, and efficiently.
DNS Record Types
DNS record types define what a domain does and where it points. Each record type has a specific role, helping the internet know how to handle websites, emails, and other services.
Types:
NS Record (Name Server)
A Record (Address Record)
AAAA Record
CNAME Record (Canonical Name)
MX Record (Mail Exchange)
TXT Record and many more..
Tip: Think of DNS records as labels and instructions that guide internet traffic. Each record type plays a specific role to ensure websites load, emails arrive, and services run smoothly.
NS Record (Name Server Record)
An NS Record tells the internet which DNS servers are responsible for a domain. In simple terms, it answers the question:
“Who is in charge of this domain’s DNS records?”
What does an NS Record do?
Points a domain to its authoritative name servers
Tells browsers and systems where to ask for DNS information
Why is the NS Record important?
Without NS records:
The domain would not work
Other DNS records (A, MX, CNAME, etc.) would never be found
Websites and emails would fail to load or deliver
Example of an NS Record
ns1.dnsprovider.com
ns2.dnsprovider.com
Key Points to Remember
Every domain must have NS records
Usually there are at least two for reliability
Changing NS records means changing the DNS provider
DNS changes may take time to update due to DNS propagation
Tip: An NS Record tells the internet where to find a domain’s DNS information.
Simple Analogy
Think of NS records as reception desks for a company. If someone wants information about a department (like a website or email), the receptionist (NS record) directs them where to go.
A Record (Address Record)
An A Record connects a domain name to an IPv4 address. It tells the internet where a website is hosted.
In simple words, it answers this question:
“Which exact address should I go to for this website?”
What does an A Record do?
Maps a domain or subdomain to a server’s IP address
Allows browsers to load websites
Is one of the most important DNS records
Example of an A Record
example.com → 192.0.2.1
Key Points to Remember for an A Record
An A Record maps a domain name to an IPv4 address
Browsers rely on it to know where to send traffic
One domain can have multiple A records (for load balancing)
Without an A record, a website cannot be accessed
Tip: An A Record is the exact address that tells the internet where a website lives.
Simple Analogy
Think of an A Record as a home's exact street address. If someone wants to visit you, just knowing your name isn't enough—they need your exact address. The A Record gives that address, telling the internet exactly where the website is located.
AAAA Record
An AAAA Record (pronounced “quad-A”) links a domain name to an IPv6 address. It works just like an A Record, but it's used for the newer version of internet addresses.
What does an AAAA Record do?
Maps a domain or subdomain to an IPv6 address
Allows websites to be reached over IPv6 networks
Example of an AAAA Record
example.com → 2001:db8:85a3::8a2e:370:7334
Key Points to Remember
AAAA records work with IPv6
A domain can have both A and AAAA records
Modern networks prefer IPv6 when available
Tip: An AAAA Record tells the internet where a website lives using an IPv6 address.
Simple Analogy
Think of an AAAA Record as a new international address format. If the old address system (IPv4) runs out of space, this new format ensures every house can still have a unique address. The AAAA record tells the internet how to reach that house using the new system.
CNAME Record (Canonical Name)
A CNAME Record lets one domain name point to another domain name instead of pointing directly to an IP address.
What problem does it solve?
Managing multiple domains or subdomains can be difficult if each one needs its own IP address.
A CNAME record solves this by allowing aliases, so when the main domain changes, everything updates automatically.
Example
www.shoppy.com → shoppy.netlify.app
Key Points to Remember
Points to another domain name, not an IP address
Commonly used for subdomains
Simplifies DNS management
Cannot be used at the root domain
Follows the target domain’s A or AAAA record
Tip: A CNAME Record creates an alias that points one domain name to another.
Simple Analogy
Think of a CNAME record as a nickname. Instead of giving someone a new home address, you give them another name that points to the same person. Wherever the person goes, the nickname still works.
MX Record (Mail Exchange)
An MX Record tells the internet which mail servers should receive emails for a domain.
What problem does it solve?
Without MX records, email systems wouldn’t know where to deliver messages sent to addresses like user@example.com.The MX record solves this by clearly defining the email destination servers.
Example
example.com → mail.example.com (priority 10)
Key Points to Remember
Required for receiving emails
Points to a mail server hostname, not an IP address
Uses priority values (lower number = higher priority)
Multiple MX records can exist for backup mail servers
Works together with TXT records
Tip: An MX Record directs incoming emails to the correct mail servers.
Simple Analogy
Think of an MX record as a mailroom address in an office building. Mail sent to the company doesn't go to random desks—it goes to the mailroom first. The MX record tells the internet which mailroom handles incoming mail.
TXT Record
A TXT Record stores text-based information in DNS. It is commonly used for verification, security, and email authentication.
What problem does it solve?
The internet needs a way to prove domain ownership and prevent email spam and spoofing.
TXT records solve this by allowing domain owners to publish trusted instructions and verification data.
Example
example.com → "v=spf1 include:_spf.mailprovider.com ~all"
Key Points to Remember
Stores plain text information
Helps prevent email spoofing
Used to verify domain ownership (Google, Microsoft, etc.)
Does not directly affect website loading
Tip: A TXT Record publishes important instructions and verification details for a domain.
Simple Analogy
Think of a TXT record as a notice board outside a house. It doesn’t tell people where the house is, but it displays important instructions like “Authorized visitors only” or “Verified owner lives here.”
How All DNS Records Work Together for One Website
When you type a website (say google.com)name into your browser, multiple DNS records work together behind the scenes to make sure the website loads correctly and emails are delivered properly.
Step-by-Step Flow
NS Record – Who is in charge
When you type
google.com, the browser first checks the NS recordsThese tell the internet which Google name servers are authoritative for
google.com
A / AAAA Record – Where the website lives
Google’s name servers return A records (IPv4) and AAAA records (IPv6)
These point to Google’s web servers that load the website
CNAME Record – Aliases (like www.google.com)
When you visit
www.google.comA CNAME record points
www.google.comtogoogle.comThis keeps DNS management simple
MX Record – Email handling
- Emails sent to
@google.comare directed using MX records to Google’s mail servers
- Emails sent to
TXT Record – Security & verification
Website uses TXT records for:
Email security (SPF, DKIM, DMARC)
Domain verification for services
Common Confusion
A Record vs CNAME Record
| Feature | A Record | CNAME Record |
|---|---|---|
| What it points to | IP address | Another domain name |
| Purpose | Finds the exact server | Creates an alias / nickname |
| Example | google.com → 142.250.190.14 |
www.google.com → google.com |
| Used for | Main websites | Subdomains |
| Can be used at root domain? | Yes | Usually No |
| Follows changes automatically? | No | Yes |
| Simple explanation | “This is the exact address” | “Go ask that domain instead” |
Simple takeaway
A Record = direct address
CNAME = shortcut to another name
NS Record vs MX Record
| Feature | NS Record | MX Record |
|---|---|---|
| What it controls | DNS management | Email delivery |
| Main question it answers | “Who manages this domain?” | “Where should emails go?” |
| Points to | Name servers | Mail servers |
| Used for | Websites, email, all DNS | Email only |
| Required for website? | Yes | No |
| Required for email? | Yes | Yes |
| Example | google.com → ns1.google.com |
google.com → mail.google.com |
| Simple explanation | Front desk of the domain | Mailroom of the domain |
Simple takeaway
NS Record = who is in charge
MX Record = where emails are delivered
Conclusion
DNS might work quietly in the background, but it is essential to how the internet operates. Every time a website loads or an email is sent, various DNS records collaborate to ensure everything runs smoothly. From identifying who manages a domain (NS records) to locating the exact server (A/AAAA records), creating shortcuts (CNAME), directing emails (MX), and enforcing security (TXT), each record has a clear and important job.
Understanding DNS records helps you go from just using the internet to truly understanding it. Whether you're building a website, setting up email, or learning the basics of networking, DNS is a key concept that links everything together.
If you enjoyed this article, check out my other blogs on this profile.
🔗 Connect with me:
LinkedIn | GitHub | X (Twitter)




