Lookup DNS records

There are multiple ways to show a domains DNS records. The simplest way is to visit viewdns.com and just type the domain name into the search box, the results will include both present and also historical DNS records if any exists. In most cases, this is the simplest way to quickly view the DNS settings, faster than using the terminal.

Viewing DNS records in the terminal (Unix and MacOS)

Speaking about the terminal, if you still like to go old school and tab out (to the terminal). Then I suggest using the command dig. It provides all the data usually needed. Let me show you:

dig viewdns.com ANY

viewdns.com.	294		IN	A
viewdns.com.	294		IN	A
viewdns.com.	172794		IN	NS	kevin.ns.cloudflare.com.
viewdns.com.	172794		IN	NS	sue.ns.cloudflare.com.

View the DNS Records on a Windows machine

Windows command prompt offers a similar tool nslookup (also available on Unix/MacOS). Its super simple to use, just type nslookup {domainname} in the command prompt and you should see something like this:

nslookup viewdns.com

Non-authoritative answer:
Name:		viewdns.com
Name:		viewdns.com

In this case the A stands for A-Pointer which contains / points to the IP used for reaching the specific website / server, NS stands for NameServers and that is where your DNS records is stored. I've written more about this on viewdns.com

Getting specific type of records (Windows / Unix / MacOS):

For supplementary studies I recommend doing a few specific queries where you include the specific type.

nslookup -type=ns viewdns.com

Non-authoritative answer:
viewdns.com	nameserver = kevin.ns.cloudflare.com.
viewdns.com	nameserver = sue.ns.cloudflare.com.

These are the most common DNS record types:

  • A - Host address, often used to point towards a websites IPv4 address
  • AAAA - Host address, often used to point towards a websites IPv6 address
  • CNAME - Canonical Name, An alias, often used as a link towards the A records
  • MX - Mail exchange, used to point towards one email server
  • NS - Authoritative name server, specifies the master DNS server responsible.
  • PTR - Domain name pointer, similar to CName but reversed, connects the IP to a domain
  • SOA - Start of authority, marks the start of a new zone
  • SRV - Service records, similar to MX but more generic and can be used for other services
  • TXT - Text strings, often used to add comments about the DNS and also validating ownership / control of domain.

I hope you learned something from this, otherwise just viewdns.com which pretty much does everything for you :)

Modern Webmaster
Richard Andersson
- Creator of WhatsMyIP.Com


I used to title myself as a Webmaster back in the late 90's, but it all slipped away during the years as a 8-17 employee.
I'm now trying to find my way back, running my own successful websites and companies.

Your Computer

Screen resolution:
Computer: Unknown
Browser: Unknown ?

View details »

WHOIS History

Search domains whois history with help of our tools. See who owned the domains before you and what has changed. View whois »

Trace IP

Avoid problems by knowing who or what you are talking with. See the geographical location of any IP address, just click the button and input the IP. Trace ip »