Which DNS Server Does Nslookup Use?


Heather Bennett

Which DNS Server Does Nslookup Use?

The DNS (Domain Name System) is a crucial component of the internet that translates human-readable domain names into IP addresses, allowing computers to communicate with each other. When you type a website address into your browser, it sends a request to a DNS server to obtain the corresponding IP address.

One common tool used to query DNS servers and retrieve information is nslookup. Nslookup is a command-line tool available on various operating systems, including Windows, macOS, and Linux. It allows users to perform DNS lookups for troubleshooting purposes or simply to gather information about domain names.

Using nslookup:

To use nslookup, open your command prompt or terminal and type nslookup. This will launch the nslookup tool in interactive mode. By default, nslookup uses your computer’s default DNS server configured by your internet service provider (ISP).

Finding the Default DNS Server:

If you are unsure which DNS server your computer is using by default, you can find out by following these steps:

  • Windows:

    • Open the Command Prompt by pressing Windows + R and typing “cmd”.
    • Type “ipconfig /all” and press Enter.
    • Look for the line that says “DNS Servers” under your network adapter’s configuration. This will display the IP address of your default DNS server.
  • macOS:

    • Open the Terminal by going to Applications > Utilities > Terminal.
    • Type “scutil –dns” and press Enter.
    • Look for the line that says “nameserver” followed by the IP address of your default DNS server.
  • Linux:

    • Open the Terminal.
    • Type “cat /etc/resolv.conf” and press Enter.

Changing the DNS Server Used by nslookup:

If you want to use a specific DNS server with nslookup, you can specify it using the following command:

nslookup <domain> <dns_server>

Replace “<domain>” with the domain name you want to look up and “<dns_server>” with the IP address of the DNS server you want to use. This allows you to query a specific DNS server rather than relying on your default DNS server.


To perform an nslookup using Google’s public DNS server (8.8.8), type:

nslookup google.com 8.8

This will query Google’s public DNS server for information about google.com instead of using your default DNS server.

In Conclusion:

Nslookup is a powerful tool that allows you to query DNS servers for information. By default, nslookup uses your computer’s default DNS server.

However, you can specify a different DNS server if needed. Understanding how to use nslookup and change the DNS server can be helpful for troubleshooting network issues or gathering specific information about domain names.

Remember, knowledge of the DNS system and tools like nslookup can empower you to diagnose and resolve various networking-related problems efficiently.

Discord Server - Web Server - Private Server - DNS Server - Object-Oriented Programming - Scripting - Data Types - Data Structures

Privacy Policy