In this complete article, we discuss Different Parts of The URL with help of some examples. Before we start, first, we have to know briefly about URLs or What are the URLs? and What is a Website URL?

What is a URL?

URL is the global address of web pages, web documents, or any file on the web or internet. URL stands for Uniform Resource Locator.
All URLs are created by multiple parts, for example protocol, domain name and parameteres.
Example:
Different Parts of The URL

- The protocol
- The domain name
- The subdomain
- Port
- Path
- Query
- Parameters
- Fragment
The Protocol
https://phpcoder.tech/php-online-editor/
The protocol is the first part of the URL and also called schema. Protocols are used to decide how files are displayed or transferred across the web.
For example HTTP (Hypertext Transfer Protocol) part of the URL represents that the page displayed in HTML format. FTP (File Transfer Protocol) which is used to transfer files local to server.
The Domain Name
The domain names are the actual address of the websites and always unique. Domain name also is the actual name of the websites.
For example domain names are like, “phpcoder.tech”, “google.com” or “google” etc.
The Subdomain
- https://subdomain.phpcoder.tech
Subdomains are generally used to create new site with a new name of our parent domain. Whatever you can create the name of the subdomain.
The Port
- https://phpcoder.tech:80
Ports are the reserved channel which are used to access the resources from the server.
Conclusion
Here we learn about the website URL, what is a website URL? and what parts are used to make a URL.
We list out the parts of URL with and image illustrator.
I hope you all are understand completely.
FAQs: Parts of the URL
The 3 basic parts of URL are,
- Protocol (HTTP or HTTPS)
- The Domain Name
- Port
Main Components of a URL,
- The protocol
- The domain name
- Port
URL stands for Uniform Resource Locator
Also Check:
- Get PHP Date Time Difference in Days, Hours, Minutes, and Seconds
- Remove Duplicates From an Array in JavaScript Without Using For Loop
- How to Set PHP Variable in JavaScript With Example
- PHP Timestamp to Date Readable Format With Example
Happy Coding..!
One Reply to “Explain Different Parts of The URL With Example”