web counter

What is the difference between a URL & a Domain?

difference between url and domain name

You may find sometimes someone asks you for your website URL (uniform Resource Locator), and sometimes it's Domain Name. Despite these terms being used interchangeably, they are extremely different. 

The major difference is:

  • URL: a string which provides the information location or complete internet address of a website. 
  • Domain Name: is a part of the URL which a more "human-friendly" version of the IP address.  


Image result for URL
Definition of URL
URL, is a reference to a web resource that specifies its location on a computer network and a mechanism for retrieving it. A URL is a specific type of Uniform Resource Identifier (URI), although many people use the two terms interchangeably. URLs occur most commonly to reference web pages (http), but are also used for file transfer (ftp), email (mailto), database access (JDBC), and many other applications.

Most web browsers display the URL of a web page above the page in an address bar.

URL contains full specification which includes a method, host name, port and path.

  • A non-empty scheme component followed by a colon (:), consisting of a sequence of characters beginning with a letter and followed by any combination of letters, digits, plus (+), period (.), or hyphen (-). Although schemes are case-insensitive, the canonical form is lowercase and documents that specify schemes must do so with lowercase letters. Examples of popular schemes include http, https, ftp, mailto, file, data and irc. URI schemes should be registered with the Internet Assigned Numbers Authority (IANA), although non-registered schemes are used in practice.
  • An optional authority component preceded by two slashes (//), comprising:
    • An optional userinfo subcomponent that may consist of a user name and an optional password preceded by a colon (:), followed by an at symbol (@). Use of the format username:password in the userinfo subcomponent is deprecated for security reasons. Applications should not render as clear text any data after the first colon (:) found within a userinfo subcomponent unless the data after the colon is the empty string (indicating no password).
    • An optional host subcomponent, consisting of either a registered name (including but not limited to a hostname), or an IP address. IPv4 addresses must be in dot-decimal notation, and IPv6 addresses must be enclosed in brackets ([]).
    • An optional port subcomponent preceded by a colon (:).
  • path component, consisting of a sequence of path segments separated by a slash (/). A path is always defined for a URI, though the defined path may be empty (zero length). A segment may also be empty, resulting in two consecutive slashes (//) in the path component. A path component may resemble or map exactly to a file system path, but does not always imply a relation to one. If an authority component is present, then the path component must either be empty or begin with a slash (/). If an authority component is absent, then the path cannot begin with an empty segment, that is with two slashes (//), as the following characters would be interpreted as an authority component. The final segment of the path may be referred to as a 'slug'.
  • An optional query component preceded by a question mark (?), containing a query string of non-hierarchical data. Its syntax is not well defined, but by convention is most often a sequence of attribute–value pairs separated by a delimiter.
  • An optional fragment component preceded by a hash (#). The fragment contains a fragment identifier providing direction to a secondary resource, such as a section heading in an article identified by the remainder of the URI. When the primary resource is an HTML document, the fragment is often an id attribute of a specific element, and web browsers will scroll this element into view.

Definition of Domain Name
The domain name was invented to simplify the IP address and make it more human convenient and friendly. An IP address is a logical address (numerical label) assigned to every computer connected to a computer network. It basically identifies the location of the computer on the internet and also helps in routing the information. For example, is an IP address. These are not so convenient to remember and hard to roll off your tongue.

The Domain Name System (DNS) converts a domain name into its specific IP address that computer want to communicate. When a user enters your domain name into a web browser, the browser uses your domain name to search and identify the correct IP address and as a result, passes the website associated with that IP address.

DNS has two distinct aspects; abstract and concrete. Abstract specifies the name syntax and rules for the names assigning authority. Concrete defines the implementation of the distributed computing system which effectively maps names to the addresses.

Domain also contains the domain extension - ie .com, .com.au - we will be blogging in the very near future in more detail about domain extensions. 

Key Differences Between URL and Domain Name
  1. The URL is the complete internet address used to locate a requested page and has a domain as its part. Whereas, Domain name is the simpler form of technical IP address which defines an organization or entity.
  2. Domain name is partitioned into levels. The labels (sub-domain, domain extension) are separated by delimiter character and follows a hierarchical naming system. On the other hand, URL provides more information than a domain name, and its partitions are method, host name (domain name), port, path, etc.

URL and domain name both seems to be similar entities, but have some differences. URL is the complete internet address of a webpage while Domain name is just the name of the organisation/individual entity along with top-level internet domains such as com, edu, gov, etc. Domain name is the short version while URL provides more detail.

Comments (0)

Leave a comment