DEV Community

Uday Yadav
Uday Yadav

Posted on • Edited on

21 3

URI | URL | URN

The world of Uniform Resource ___

sum-up

Here the word resource could be anything, take it as a img on your computer for easier understanding

URI

  • URI stands for Uniform Resource Identifier
  • A URI contains two things
    • Name
    • Location
  • We need URI so identify the resource from its name and also be able to locate it using location

URL

  • URL stands for Uniform Resource Locator
  • This is basically the address of the resource.

URN

  • URN stands for Uniform Resource Name
  • This is basically the name of the resource.

Therefore : URI = URL + URN

The URI generic syntax consists of a hierarchical sequence of five components

URI = scheme:[//authority]path[?query][#fragment]
Enter fullscreen mode Exit fullscreen mode

where the authority component divides into three subcomponents:

authority = [userinfo@]host[:port]
Enter fullscreen mode Exit fullscreen mode
             host   port
          ┌───┴───┐ ┌─┴┐
  https://localhost:8080/forum/q/?tag=networking#top
  └─┬─┘   └───────────┬──────────────┘└───────┬───────┘ └───────────┬─────────────┘ └┬┘
  scheme          authority                  path                 query           fragment
Enter fullscreen mode Exit fullscreen mode

I hope you like this article !

Speedy emails, satisfied customers

Postmark Image

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up

Top comments (4)

Collapse
 
cstryker profile image
Colin Stryker

I've been conflating the two for years. This is helpful to actually get a simple explanation. Thanks!

Collapse
 
zippytyro profile image
Shashwat Verma

This is really helpful man, I used to think while reading about URL and URI.

Collapse
 
ppezaris profile image
ppezaris

Excellent information, thanks!

Collapse
 
alfiannsx98 profile image
Irman itu Aku

Nice info. Thankss

Billboard image

Create up to 10 Postgres Databases on Neon's free plan.

If you're starting a new project, Neon has got your databases covered. No credit cards. No trials. No getting in your way.

Try Neon for Free →

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay