A URL, or Uniform Resource Locator, is a specific type of Uniform Resource Identifier (URI) that provides a means to access a resource on the internet. Here are the main components and features of a URL:
Protocol: This indicates the method used to access the resource. Common protocols include:
http://
(Hypertext Transfer Protocol)
https://
(HTTP Secure)
ftp://
(File Transfer Protocol)
Domain Name: This is the human-readable address of the website, such as www.example.com
. It identifies the server that hosts the resource.
Port (optional): This number can specify a particular port on the server. If omitted, the default ports are used (80 for HTTP and 443 for HTTPS). For example, :8080
might be included in a URL if a non-standard port is being used.
Path: This indicates the specific location of a resource on the server. For example, /folder/page.html
points to a specific HTML page within a directory.
Query String (optional): This is used to pass parameters to the server, often seen in search queries. It starts with a ?
and can include multiple parameters separated by &
. For example: ?search=keyword&sort=ascending
.
Fragment (optional): This is used to navigate to a specific part of a webpage and starts with a #
. For example, #section1
would take the user to a specific section of the page.
https://www.example.com:443/folder/page.html?search=keyword#section1
In this example:
Protocol: https
Domain Name: www.example.com
Port: 443
(optional and often omitted)
Path: /folder/page.html
Query String: ?search=keyword
Fragment: #section1
URLs are essential for navigating the web, as they provide the addresses needed to locate resources.
URLs shortened here expire in 30 days. However, each visit extends the URL expiration by another 30 days!