

Ask HN: Why are commas not allowed in urls? - tronium

I&#x27;ve always been curious why certain characters (e.g. commas) haven&#x27;t been allowed in the url. I&#x27;ve never seen one used in a specialized way at all, are they just nonexistent in usage? If so, why?
======
daveslash
My best guess. From RFC 3986 (link below)

 _For example, the semicolon ( ";") and equals ("=") reserved characters are
often used to delimit parameters and parameter values applicable to that
segment. The comma (",") reserved character is often used for similar
purposes. For example, one URI producer might use a segment such as
"name;v=1.1" to indicate a reference to version 1.1 of "name", whereas another
might use a segment such as "name,1.1" to indicate the same._

[http://www.ietf.org/rfc/rfc3986.txt](http://www.ietf.org/rfc/rfc3986.txt)

EDIT: This RFC is for URIs and your question was about URLs. URLs are
generally considered a subset of URIs, but according to this SO answer, that
might be open to debate. [http://stackoverflow.com/questions/176264/whats-the-
differen...](http://stackoverflow.com/questions/176264/whats-the-difference-
between-a-uri-and-a-url)

~~~
tronium
Thanks dave, that helped explain a little. However, I still have never
actually seen a comma used as a parameter in a URL, do you have an example?

~~~
randallma
The Onion has their article urls in the format:

[http://www.theonion.com/articles/scientific-community-
baffle...](http://www.theonion.com/articles/scientific-community-baffled-by-
man-whose-waist-32,36157/)

/articles/slug,id/

~~~
daveslash
Wow, thanks, I don't think I'd ever noticed a URL with a comma. I don't think
it's a valid* URL, but apparently it's definitely do-able.

*valid == conforming to spec.

------
rahimnathwani
Vignette StoryServer, a CMS from back in the day, had commas in all (or almost
all) the URLs it generated.

[http://en.wikipedia.org/wiki/StoryServer](http://en.wikipedia.org/wiki/StoryServer)

