Skip to main content

Command Palette

Search for a command to run...

DNS Record Types Explained

Updated
4 min readView as Markdown
DNS Record Types Explained
V
Vishal Gupta Android dev in progress. Building toward SaaS — one shipped product at a time. I care about reliability over hype. Still learning, but I build things that work.

Hey buddy ,

Have you any Idea how when i put just domain name and browser provide you that domain content show on that browser .

So the question is how the browser reach that domain‘s server and grab their content and show us eon browser ?

we are just learn about this how these all thing have done by browser .

What is DNS :

DNS stand for Domain Name Server . Which work is like a phone-book (put name and get number ) so same thing done DNS , take Domain name and in the return give their IP address .

DNS has it’s type (DNS working different) :

A record :

  • This record hold/contain IP address of domain

  • A records hold IPv4 address

    | example.com | record type: | value: | TTL | | --- | --- | --- | --- | | @ | A | 192.0.2.1 | 14400 |

  • TTL (Time to live) , it means if A records update then it take 240 minutes

AAAA record : This record hold IPv6 address of domain

Here is an example of an AAAA record:

example.comrecord type:value:TTL
@AAAA2001:0db8:85a3:0000:
0000:8a2e:0370:733414400

CNAME record :

  • Forward domain or subdomain to another domain , does NOT provide an IP address .
blog.example.comrecord type:value:TTL
vishalcode.comCNAMEchaicode.com32600

It means if someone solve DNS query of vishalcode.com then that got CNAME domain (chaicode.com), and dns query on chaicode.com then you got IP address (e.g.: 2.3.4.5) of vishalcode.com .

Vercel :

Vercel have do same thing, as you know may website host on vercel , have you thing what if vercel has crash or Vercel migrate his server (e.g. 76.76.1.1 → 95.95.1.1) so if all his user add A record only in his Domain then all user need to update A record . Because as you now in A record keep IP address of server . So what if i put CNAME record of Vercel, in my Domain (assume this domain host on vercel) , it means if even though vercel change it server i have no issue because cname.vercel.conm automatic point to vercel server . If vercel change it’s CNAME also then we also need to manually update CNAME in my Domain .

CNAME tell where original address

MX record :

  • Mail exchange record these record directs email to mail server

  • MX record route mail message accordance with smtp (simple mail transfer protocol)

example.comrecord type:priority:value:TTL
@MX10mailhost1.example.com45000
@MX20mailhost2.example.com45000

TXT record :
The DNS `txt record` is contain data and these data may be Computer readable language or human readable language instruction .

it is use for many purpose , Domain Ownership verification , email spam prevention etc. .

example.comrecord type:value:TTL
@TXT"This is an awesome domain! Definitely not spammy."32600
example.comrecord type:value:TTL
@TXTgoogle-site-verification=G9xA8kDjs92kKsjDUw92ksLQpZ32600

NS record :

NS stands for ‘nameserver‘ , it tell to the internet where go to and find domain IP address .

example.comrecord type:value:TTL
@NSns1.exampleserver.com21600

Which Server has power to DNS control to this Domain. It means nameserver control DNS records

I hope you guys , this blog helps you !

Nsync Bye Bye Bye GIFs - Find & Share on GIPHY

More from this blog

V

Vishal Kumar Gupta

22 posts

Hello , This is Vishal here , i strat writing blog with my web-cohort 2026 journey . Yeah this is helpful for me to understand myself how can i capable to put my thought throgh the blog