Skip to main content

What is a domain name?

A domain name is a human-readable name for a resource on the internet, used instead of an IP address, that indicates how to find a site or service.

In simpler terms: a domain name is the name of a site that a person types in.


Why a domain name is needed

Computers work with IP addresses, for example:

93.184.216.34

Such addresses are inconvenient for people, so names are used instead:

  • google.com
  • github.com
  • example.org

A domain name makes the internet convenient for people, while DNS is what turns it into an IP address.


How a domain name is used

When you type in the browser:

example.com

the following happens:

  1. the browser takes the domain name
  2. it finds out the IP address through DNS
  3. it connects to the server by IP

The domain name itself is not a server and not a site, it is a pointer used to find them.


What a domain name consists of

Take this example:

www.example.com

1. Top-level domain (TLD)

.com
  • indicates the domain zone
  • examples: .com, .ua, .org, .net, and others

2. Second-level domain

example
  • the site's main name
  • most often the name of a company or project

3. Subdomain (optional)

www
  • used to separate services
  • can be: api.example.com, mail.example.com

Important point for an interview

  • a domain name is not the same as an IP address
  • one domain can point to:
    • one IP
    • several IPs (load balancing)
  • the IP can change while the domain name stays the same

Real-life example

A domain name is like:

  • a person's name in a phone book
  • you know the name, but the number can change

DNS is the phone book itself.


Short interview answer

Remember this formulation:

A domain name is a character-based, human-friendly name for a resource on the internet that DNS translates into an IP address and that is used to access sites and services.

Short Answer

Interview ready
Premium

A concise answer to help you respond confidently on this topic during an interview.