Skip to content
— CH. 1 · INTRODUCTION —

JSON

~6 min read · Ch. 1 of 7
7 sections
  • JSON, which stands for JavaScript Object Notation and is pronounced either JAY-son or JAY-sawn, carries an unusual distinction for a data format: its name sounds exactly like a person's name. That coincidence was no accident. The format's creator, Douglas Crockford, was well aware of the parallel, and in 2011 he cheerfully declared, "There's a lot of argument about how you pronounce that, but I strictly don't care."

    Crockford and a colleague named Chip Morningstar sent the very first JSON message in April 2001. Within a few years, that simple act of transmission had set off a quiet transformation in how the web exchanged information. Today JSON is everywhere, the default language through which web applications talk to servers, databases talk to developers, and devices talk to each other.

    How did a format with roots in a children's trading game become an internet standard ratified by bodies in Geneva and Washington? And what exactly is hiding inside those curly brackets?

  • In the early 2000s, getting a web browser to talk to a server in real time meant relying on browser plugins like Flash or Java applets. These plugins were the dominant method of achieving live, back-and-forth communication, but they were heavyweight, proprietary, and not universally available.

    Crockford and his co-founders at State Software, a company they started in March 2001, set themselves a different goal. They wanted to build interactive web applications using only what browsers already had built in, without asking users to install anything extra. Their approach involved holding two HTTP connections open simultaneously and recycling them before standard browser timeouts kicked in, maintaining what they called a persistent duplex connection.

    The co-founders sat around a table and voted on what to call the new data format. The candidates were JSML, short for JavaScript Markup Language, and JSON. JSON won. What they needed was a lightweight way to pass structured data through those recycled connections, and they found it by recognizing that JavaScript itself could serve as an object-based messaging format. The system they built was eventually sold to Sun Microsystems, Amazon.com, and EDS.

  • Before State Software existed, there was Cartoon Orbit, a children's digital asset trading game run by a company called Communities.com. A precursor to the JSON libraries appeared there first, embedded in a browser-side plugin that used a proprietary messaging format to manipulate page elements in real time.

    It was through this early experiment that developers discovered what browsers could already do. Teams at companies called digiGroups and Noosh began using frames to push information into a browser's visible field without forcing a full page refresh. They were doing this with Netscape 4.0.5 and Internet Explorer 5, using nothing but standard HTTP, HTML, and JavaScript.

    Crockford recognized that this Ajax-like capability, long before the term Ajax was coined, could carry structured data shaped like JavaScript objects. The JSON.org website went live in 2001, and by December 2005 Yahoo! was offering some of its web services in JSON format. That adoption by Yahoo! was an early sign that the format had outgrown its origins in a startup's conference room.

  • JSON stores data as name-value pairs inside curly brackets, and lists of values inside square brackets. A key is always a string in double quotation marks, a colon separates it from its value, and commas separate each pair from the next.

    The format recognizes six data types. Numbers can be signed decimals with fractional parts or exponential notation, but not values like NaN. Strings are sequences of Unicode characters, delimited by double quotation marks. Booleans are simply the words true or false. Arrays are ordered lists in square brackets. Objects are collections of key-value pairs in curly brackets. And null represents an empty value.

    Whitespace is allowed anywhere between elements and is simply ignored. Four characters count as whitespace: space, horizontal tab, line feed, and carriage return. One thing JSON deliberately leaves out is comments. Crockford explained in 2012 that he removed them after seeing developers use them to embed parsing instructions, a practice he believed would have broken interoperability between different systems. His suggested workaround was to strip comments with a tool called JSMin before feeding the text to a JSON parser.

  • JSON operated for years under an informal specification before formal standards bodies got involved. RFC 4627 had served as an informational reference since 2006, but the first true standard arrived in October 2013, when Ecma International published ECMA-404.

    Four years later, in November 2017, ISO/IEC JTC 1/SC 22 published its own standard, ISO/IEC 21778:2017. Then on the 13th of December 2017, the Internet Engineering Task Force published RFC 8259, the current version of Internet Standard STD 90. The ECMA and ISO/IEC documents cover only syntax; the RFC additionally addresses security and interoperability considerations.

    Before any of this, Crockford had introduced a clause into the JSON license that stated, "The Software shall be used for Good, not Evil." He framed it as a way to open-source the libraries while gently mocking corporate lawyers and those he saw as overly pedantic. The clause did carry a real consequence: it created compatibility problems with other open-source licenses, since standard open-source and free software definitions permit no restrictions on the purpose of use.

  • JSON's simplicity is also a source of friction. Because the specifications place no limit on the magnitude or precision of numbers, different implementations handle edge cases differently. JavaScript itself stores all numbers as IEEE 754 binary64 values, and for broad compatibility the RFC recommends not transmitting numbers outside that range, citing values like 1E400 or the extended decimal expansion of pi as examples that could cause problems.

    Duplicate key names are another hazard. The ECMA standard explicitly permits JSON objects to contain multiple members sharing the same name, but it says nothing about what implementations should do with them. The behavior is left unpredictable, and the practical guidance is to simply avoid sending duplicate keys at all.

    In 2015, the IETF published a specification describing the "I-JSON Message Format," a restricted profile of JSON designed to head off as many of these interoperability issues as possible. On the character encoding side, while the specifications technically permit other encodings, nearly all implementations assume UTF-8, and RFC 8259 requires UTF-8 for open-ecosystem exchange. The format supports the full Unicode character set, including characters beyond the Basic Multilingual Plane, which runs from U+0000 to U+FFFF.

  • JSON's deliberate minimalism left room that other formats rushed to fill. Comments, trailing commas, and unquoted keys are all features JSON excludes by design, and the absence of each generated its own workaround.

    JSON5, whose specification was started in 2012 and finished in 2018 with version 1.0.0, adds optional trailing commas, unquoted object keys, single-quoted and multiline strings, additional number formats, and comments, while remaining valid JavaScript syntax. HJSON and HOCON pursue similar goals: HOCON, which stands for Human-Optimized Config Object Notation, is used as the primary configuration format for TIBCO Streaming products including StreamBase and LiveView, as well as for subsystems of Exabeam Advanced Analytics and for Jitsi. YAML version 1.2 is a full superset of JSON, though earlier YAML versions were not strictly compatible.

    Beyond configuration, JSON spawned a family of specialized derivatives. GeoJSON handles geographical features. JSON-LD encodes linked data. JSON-RPC is a remote procedure call protocol built on JSON, intended as a replacement for XML-RPC or SOAP. UBJSON is a binary format that imitates JSON while using fewer bytes. Jsonnet extends JSON with variables, imports, loops, and comments, and is used as a configuration language for cloud infrastructure. Relational databases including PostgreSQL and MySQL have added native JSON data types, with PostgreSQL offering a binary storage variant called JSONB.

Common questions

Who invented JSON and when was it created?

Douglas Crockford originally specified the JSON format in the early 2000s. He and Chip Morningstar sent the first JSON message in April 2001, and the JSON.org website launched that same year.

What does JSON stand for and how do you pronounce it?

JSON stands for JavaScript Object Notation. The 2017 international standard specifies the pronunciation as JAY-son, as in "Jason and The Argonauts," though JAY-sawn is also widely used. Crockford himself said in 2011 that he strictly does not care about the pronunciation.

When was JSON officially standardized?

JSON was first standardized in October 2013 as ECMA-404. It was then standardized as ISO/IEC 21778:2017 in November 2017, and on the 13th of December 2017 the Internet Engineering Task Force published RFC 8259, the current Internet Standard STD 90.

Why does JSON not support comments?

Crockford deliberately removed comments from JSON after observing developers using them to embed parsing directives. He explained in 2012 that this practice would have destroyed interoperability between different implementations.

What are the basic data types supported by JSON?

JSON supports six data types: Number, String, Boolean (true or false), Array, Object (a collection of key-value pairs), and null. Strings must be enclosed in double quotation marks, arrays use square brackets, and objects use curly brackets.

What is the "Good, not Evil" clause in the JSON license?

Crockford added the clause "The Software shall be used for Good, not Evil" to the JSON license as a way to open-source the libraries while mocking overly pedantic corporate lawyers. The clause created license compatibility problems because standard open-source definitions permit no restrictions on the purpose of use.

All sources

80 references cited across the entry

  1. 1av mediaThe JSON SagaDouglas Crockford — YUI Library — 2011-08-28
  2. 2webPronounsDouglas Crockford — December 8, 2022
  3. 3webECMA-404: The JSON Data Interchange SyntaxEcma International — December 2017
  4. 8webJSON
  5. 10webIntroducing JSONDouglas Crockford — json.org — May 28, 2009
  6. 13webJSON in JavaScriptDouglas Crockford — 2016-07-10
  7. 14webJSON: The JavaScript subset that isn'tHolm, Magnus — The timeless repository — 15 May 2011
  8. 16harvnbECMA-404, 2nd ed.
  9. 17reportPrinting Floating-Point Numbers: An Always Correct MethodMarc Andrysco et al. — 18 February 2016
  10. 18webComments in JSONDouglas Crockford — 2012-04-30
  11. 20webJSON5json5
  12. 21harvnbECMA-404, 2nd ed. p. iiiECMA-404, 2nd ed.
  13. 24journal11. IANA ConsiderationsTim Bray — IETF — December 2017
  14. 28journalJSON Reference: draft-pbryan-zyp-json-ref-03Kris Zyp — September 16, 2012
  15. 29webJSMinDouglas Crockford — 2019-05-16
  16. 40webAmazon IonAmazon
  17. 43webXML 1.1 SpecificationWorld Wide Web Consortium
  18. 44bookClient-server web apps with Javascript and JavaCasimir Saternos — O'Reilly Media, Inc. — 2014
  19. 45bookNetwork Programmability and AutomationJason Edelman et al. — O'Reilly Media
  20. 48webWhy JSON isn't a good configuration languageThayne McCombs — Lucid Chart — July 16, 2018
  21. 49webCoffeeScript Object NotationLee Dohm — 2014
  22. 51webCSONBevry — 20 Dec 2023
  23. 52webCSONKang Seonghoon — 2021-07-01
  24. 62webConfig phase 1JITSI Project
  25. 63webreference.confJITSI Project
  26. 67bookVisual Studio Code DistilledAlessandro Del Sole — Apress — 2023
  27. 68bookBuilding Browser ExtensionsMatt Frisbie — Apress — 2025
  28. 69journalRFC 7946 - The GeoJSON FormatH. Butler et al. — August 2016
  29. 70webGeoJSON
  30. 71webJSON-LD 1.12020-07-16
  31. 75citationJsonMLStephen McKamey — 2022-06-14