What DNS is and how it works: the phone book of the internet

When you type a website address, the right page loads in a fraction of a second. DNS takes care of that, and it is called the phone book of the internet. Let us explain clearly what DNS is, how it works and why it is worth knowing about.
What DNS is
Computers communicate with each other through numbers, so-called IP addresses, but people remember names far better. DNS (Domain Name System) is the service that translates domain names into IP addresses. When you type tiptech.sk, DNS finds the IP address of the server the site runs on. So it works exactly like a phone book: you enter a name and get a number.
How it works, step by step
- You type the site name into the browser.
- The computer asks a DNS server what IP address belongs to it.
- The DNS server returns the IP address.
- The computer connects to that IP and the page loads.
The whole thing happens in a fraction of a second and you see none of it.
Where the computer asks: the DNS hierarchy
DNS is not one server but a chain. The computer first looks in its own memory (cache), then asks a DNS resolver (usually at the provider or a public one), which through the root servers and the top-level domain server (for example .sk) reaches the authoritative server of the given domain. That one knows the final answer. It sounds complicated, but in practice it is lightning fast.
DNS cache: why a change takes a while
So that everything does not have to be looked up afresh every time, answers are stored in memory (cache) for a certain time. Each record has its lifetime (TTL). That is exactly why after a DNS change (for example when moving a website) the new address does not take effect immediately, but only once the old answer in memory expires.
Public DNS servers
Besides DNS from the provider, there are also public servers, for example 8.8.8.8 from Google or 1.1.1.1 from Cloudflare. They are sometimes faster or more reliable, and setting them can help when the provider’s DNS fails.
Why it is good to know about DNS
When the internet does not work even though the connection is fine, DNS is often to blame. Then switching to a different DNS server sometimes helps. DNS can also be used for filtering, that is blocking dangerous or unsuitable sites, which is handy for parental controls and security.
Security: DNS and scams
DNS can also be a target of attack. A forged record can redirect you to a fake site that looks like the real one (so-called pharming). That is why encrypted DNS is gaining ground, and always check that you are on the right address with HTTPS, especially when logging in and paying. This is related to protection against fraudulent sites.
Do you have an internet problem that does not look like a line fault? Get in touch, we will also check the DNS settings and the network as a whole. You will find related terms in the article networking basics.
This article is part of our Computer networks overview.
Need help with IT?
We will take care of your computers, networks and security - for businesses and households in the Liptov region.
Contact us