DEV Community

Discussion on: What Is The Difference Between A URI And A URL?

Collapse
 
flippedcoding profile image
Milecia

Here's a URI that's not a URL:
example.test.com

The reason that this is not a URL is because this system could respond to different protocols.

This URI could have a URL like any of these:
ftp://example.test.com
example.test.com
example.test.com

Hopefully that makes sense!

Collapse
 
vibertthio profile image
Vibert Thio

I don't think example.test.com is a valid URI. In RFC3986:

URI = scheme ":" hier-part [ "?" query ] [ "#" fragment ]

And it didn't say anything about that schema can be ignored. Also ":" seems to be necessary in the definition. Am I thinking wrong?