Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What's the difference between Hostname and Domain name? especially in regards to NIC

Could someone please elaborate with examples as this concept is a little confusing

share|improve this question
up vote 38 down vote accepted
  • hostname is the name given to the end-point (the machine in question)
    • and will be used to identify it over DNS if that is configured
  • domain is the name given to the 'network'
    • it will be required to reach the network from an external point (like the Internet)

It is usually written in the form, -- for example

If you are in (say) a college campus named called 'The-University',
and its domain is called '',
a machine on the campus network called 'mymachine' would be addressed as, ''.

If you were trying to connect to this machine from your home network,
you would address it with that full name.
The domain part would reach you to the campus network
and the hostname would let you reach the exact machine in the campus.
I am avoiding the details of IP Addressing and gateways here.

For this reason, while accessing the machine from another machine within the campus
may work with just the hostname (mymachine) without the use of the domain name.

To taken an analogy, if you are in the same city, the street name suffices.
But, to address a place in another city, you would usually add the city name after the street.

For a more detailed reading
the Wikipedia page on Domain Name Service could be a good starting place.

  • When configuring DNS, the DNS Server Name would be required.
    This is a hostname (the server is an addressable machine).
  • An IP address cannot point to a Domain Name,
    It can however point to a domain name server (DNS).
share|improve this answer
would i have to mention the hostname somewhere when configuring the dns? and if I have a static IP pointing to the domain name would I have to mention the hostname anywhere or that is independent of the domain name configuration – rzlines Oct 22 '09 at 20:52
what if i add an A record then isn't that an IP pointing to a domain name? or vice versa? – rzlines Oct 22 '09 at 21:24
I disagree. A domain is not limited to a physical location, and not even to a specific network! – Arjan Oct 23 '09 at 7:27
@Arjan, I accept your disagreement. I have 'over' simplified in the answer. – nik Oct 23 '09 at 8:07
@CiroSantilli六四事件法轮功包卓轩 They are both hostnames. The name www by itself is unqualified, and you are quite correct that it will only resolve properly "internally". In fact, it will resolve differently depending on a network's DNS configuration. The name is a fully qualified domain name (FQDN; which unfortunately confuses the distinction between "host name" and "domain name") and should resolve the same from any system connected to the Internet. – kbolino Nov 3 '15 at 17:09

What is the difference between hostname and domain name?

A domain is something which you register and which points to your DNS servers*0. These DNS servers*1 can answer queries for hosts within that domain.

Note that these hosts do not have to be on the same network.

Gameforge*2 is a firm with some 'Freemium' games. It has servers in multiple countries. It has one single domain called may point to a server in the UK (and an a network in the UK), while may point ot a server in Germany.

Network location and is not tied to the domain name.

A host is a computer on a network. That host can have one more more NICs and can have IP adresses. In the case of most home computers the desktop or laptop has one active NIC and one IP, but it is possible to have multiple IPs per NIC, or use multiple NICs. For more details on that look up multi-home.

Especially in regards to NIC

In the case of most home computers the desktop or laptop has one active NIC and one IP, but it is possible to have multiple IPs per NIC, or use multiple NICs. For more details on that look up multi-home.

I hope that this last part answers the 'in regards to NIC'. If not then please specify your question a bit more.

*0 Or to the DNS servers of someone who manages your domain for you.
*1 At least two DNS servers in different locations are recommended.
*2I am not affiliated with them. It is just the first example I thought of.

share|improve this answer

A hostname is the name of a server, on a local network it can be a simple name like "mailserver".

For use on the Internet, domain name and hostname is for most practical purposes the same thing.

See related Wikipedia link.

Read more:

share|improve this answer
It is not even a Wikipedia. – Nakilon Apr 19 '13 at 11:39
Hostname and domain name are very much NOT the same. I suspect that you answered this with a very limited an specific example in mind (e.g. domain.tld and domain.tld. But most domains will have many servers, each with their own hostnames. E.g. fileserver-1.domain.tld, printerser.domain.tld, my_desktop.domain.tld, mylaptop.domain.tld, etc etc. Your example ignores all this and only makes limited sense when you consider that web and mail (MX record!) are often mapped to the same place. However those are the exceptions! – Hennes Jul 14 '14 at 6:02

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.