URI is short for Uniform Resource Identifier. This generic term is used for all types of names and addresses that refer to Internet objects such as pages, images, videos, etc.
A URI is therefore a string of characters that are used to identify a resource or a name on the Internet. Its purpose is to allow interaction between different resources on the Internet and another type of network.
Table of Contents
Difference between URI and URL
A URL (Uniform Resource Locator) is mainly used to point to a web page or a part of it with schemes or protocols such as http, https, ftp or mailto, in order to facilitate access to the location of the resource.
Meanwhile, URI (Uniform Resource Identifier) is used to define the identity of an object, regardless of the method used.
We can claim that a URL is a URI, while a URI may not be a URL.
Types of URIs
- IRI: International resource identifier. This is a generalization of the URI that fully supports international characters. Unlike the URI that only supports ASCI encoding.
- URL: Uniform Resource Identifier. It is a URI that indicates the location of a resource on the Internet and allows you to locate it.
- URN: Uniform Resource Name: Uniform name of resources. This specialized string indicates the name of a resource that is unique on the Internet. The URN indicates a unique and public name of a resource on the Internet.
- URC: Uniform Resource Citation: Uniform citation of resources. A set of values that describe an object. It is a URI that is used to include author, date, copyright…
The schema in a URI serves to classify the URI based on what it is found before the colon. Some examples would be the following:
- http: is the most common scheme when browsing the Internet.
- https: schema used in for secure pages with SSL certificate
- mailto: scheme used for email addresses.
- ftp: scheme used to transfer files by ftp