SCRIPT5009: 'JSON' is undefined SCRIPT5009: 'JSON' is undefined json json

SCRIPT5009: 'JSON' is undefined


See here for a blog post explaining the situation: Resolve JSON is Undefined Error in Internet Explorer

Include the JSON library in your page and you should be good to go.


JSON is not available in compatibility mode IE:

Not supported in the following document modes: Quirks, Internet Explorer 6 standards, Internet Explorer 7 standards.

Since you shouldn't be using (or worse, reyling on ) compatibility modes in the first place, you should switch IE to standards-mode by adding a valid doctype.


Yes, JSON is defined natively in modern browsers, but not in IE. You need to import a library. For example, http://ajax.cdnjs.com/ajax/libs/json2/20110223/json2.js