What does DNS do?
Options
- It encrypts the traffic between browser and server
- It maps a domain name to a server IP address (Correct option)
- It stores the files that make up the website
- It balances the CPU load across the servers
Answer
Translates a domain name like example.com into the IP address of a server
Why
Computers connect using IP addresses (e.g. 93.184.216.34), but people remember names.
DNS (Domain Name System) works like the internet's phone book: your device asks a DNS resolver 'what is the IP of example.com?' and gets the address back. Results are cached for a while (TTL).
DNS can also route users to nearby servers.
Remember
DNS = name → IP address.