views:

19

answers:

1

Is there a standard or specification which defines json file extensions?

I've seen .json used - is this just a commonly accepted practice or is it a requirement of some standards body for json saved in file format?

+3  A: 

According to Douglas Crockford's draft of the JSON format found here:

"A JSON parser transforms a JSON text into another representation. A
JSON parser MUST accept all texts that conform to the JSON grammar. A JSON parser MAY accept non-JSON forms or extensions."

So, it's just a commonly-accepted practice; as long as your file conforms to the JSON grammar the extension doesn't necessarily need to be *.json (although it can certainly be helpful to you and other developers if it is).

Donut