The term 'HostName' refers to the name given to a particular machine that is part of a computer network. The machine can be a simple computer, a network server, a network printer, a fax machine or copier, a modem, a network storage device or any other electronic device connected to a network. Each of these machines can be assigned a unique hostname by which they are identified in the network.
There are various naming systems used to assign hostnames and each of them has their own naming convention that is incompatible with the rest. The most popular naming system used on the Internet is the DNS or Domain Name System which identifies the host computer on which the website resides. The name of the host computer is mentioned first, followed by a period which is in turn is followed by the domain name.
The domain name is made up of a series of labels separated by periods. Spaces within or between labels are not permitted. When all the labels including the top level domain name (TLD) are specified, the resulting name is referred to as a Fully Qualified Domain Name or FQDN. In the case of incomplete or unqualified hostnames, they are normally combined with their particular system's default domain name to determine the FQDN. Strictly speaking, FQDNs need to end with a period but in practice they are usually omitted. Each label can be up to 63 characters but the entire FQDN cannot exceed 255 characters.
There are certain rules that determine what exactly constitutes a valid hostname. For instance, a hostname can contain only alphabets 'a' through 'z', numerals '0' through '9' and the hyphen. Other special characters including the 'underscore' are not allowed although some domains names use them.
As an example, if a company's domain name is abc.com and a computer named CEO is part of the network, that particular computer's FQDN would be ceo.abc.com. including the final period although it can be omitted. The entire FQDN would be referred to as the 'hostname'.