Getting your DNS settings means retrieving the Domain Name System servers your device uses to translate website names into IP addresses. This process reveals the specific DNS resolvers configured on your network interface.
DNS acts as the internet's phonebook. When you type "google.com" into a browser, your device contacts a DNS server to find the correct IP address-like 142.250.180.46-so it can load the site. Knowing which DNS servers your system uses helps troubleshoot connectivity issues, improve privacy, or bypass regional restrictions.
Every device on a network relies on DNS to function. Without it, typing a website name would fail. Your operating system automatically fetches DNS settings via DHCP on most home networks, but you can manually check or change them anytime.
Your device sends a DNS query to a configured resolver. The resolver checks its cache first. If the result isn't cached, it queries root servers, then top-level domain servers, and finally authoritative servers for the requested domain. This chain completes in milliseconds.
For example, when you visit "wikipedia.org," your device asks a DNS server, "What's the IP for wikipedia.org?" The server responds with 91.198.174.192. Your browser then connects to that IP address to load the page.
If your DNS server is slow or compromised, websites may load slowly or redirect to malicious sites. Using public DNS services like Cloudflare (1.1.1.1) or Google Public DNS (8.8.8.8) often improves speed and security.
On Windows, open Command Prompt and run:
ipconfig /all
Look under your active network adapter for "DNS Servers." The listed IPs are your current DNS resolvers.
On macOS, open Terminal and enter:
scutil --get DNS
The output shows a list of DNS servers. For example:
{
nameserver[0] = 192.168.1.1
nameserver[1] = 1.1.1.1
}
This means your Mac uses your router (192.168.1.1) and Cloudflare's public DNS (1.1.1.1).
On Linux, use:
cat /etc/resolv.conf
Output might show:
nameserver 8.8.8.8
nameserver 8.8.4.4
These are Google's public DNS servers.
Many users confuse DNS with IP addresses. DNS translates domain names to IPs. IP addresses identify devices on a network. You don't "get" your IP by running a DNS command-it's a different layer of networking.
Another error: assuming all DNS servers are equal. Some ISPs route queries through monitoring systems that log browsing habits. Public DNS services like Cloudflare and OpenDNS offer better privacy and filtering options.
A lesser-known fact: DNS queries can be encrypted using DoT (DNS over TLS) or DoH (DNS over HTTPS). These prevent snooping on your traffic. Most modern browsers and OSes support them, but they're not enabled by default.
Use "get my dns" when troubleshooting slow web loading, blocked sites, or incorrect redirects. If a site loads incorrectly or fails entirely, your DNS may be misconfigured or hijacked.
For example, I once encountered a user whose Netflix app wouldn't start. After checking their DNS settings, I found they were using a router that had been compromised. The DNS was pointing to a fake server. Switching to 1.1.1.1 restored access immediately.
Network administrators often verify DNS settings during audits. A mismatch between expected and actual DNS servers can signal a configuration issue or security breach.
There are four main types of DNS servers:
| Type | Function | Example |
|---|---|---|
| Recursive Resolver | Answers queries on behalf of clients | Cloudflare 1.1.1.1 |
| Root Server | Starts the DNS lookup chain | 198.41.0.4 (a.root-servers.net) |
| Top-Level Domain (TLD) Server | Manages domains like .com or .org | gTLD servers operated by ICANN |
| Authoritative Server | Holds the official records for a domain | ns1.google.com for google.com |
You typically interact only with recursive resolvers. They handle the rest of the lookup process behind the scenes.
Using your ISP's default DNS server means they can log every site you visit. Public DNS providers like Cloudflare and Google offer enhanced privacy policies. Cloudflare states it doesn't log user IP addresses or query details beyond minimal metadata for abuse prevention.
According to Cloudflare's transparency report (2023), they do not store DNS query logs longer than 24 hours and do not sell data to third parties. Google's policy similarly limits retention.
For maximum privacy, enable DNS over HTTPS (DoH) in your browser or operating system. Firefox and Chrome both support DoH. On Linux, you can configure it via systemd-resolved.
Once you've retrieved your current DNS settings, you can switch to a preferred service. To change DNS on Windows:
On macOS, go to System Settings > Network > Select interface > Details > DNS. Click the + button and add new servers.
On Linux, edit /etc/resolv.conf or configure via NetworkManager. Always back up the original file before making changes.
After changing DNS, test with:
nslookup google.com
If the response returns an IP from your new DNS provider, the change took effect.
Understanding how to get your DNS is essential for diagnosing network problems and improving online safety. securing your browsing, knowing your DNS setup gives you control.