JSON Basics/Root string

A single JSON string is also valid JSON.

Section: Valid JSON roots

Root string

json
json
"hello world"
Explanation

Many developers expect only objects or arrays, but any valid JSON value can be the root.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Valid JSON roots
Root object
A JSON document can start with an object.
OpenIn sheetjsonsame section
Root array
A JSON document can start with an array.
OpenIn sheetjsonsame section
Root number
A number can be the entire JSON document.
OpenIn sheetjsonsame section
Root null
`null` is valid as a complete JSON document.
OpenIn sheetjsonsame section
Use double quotes for keys and strings
JSON requires double quotes, not single quotes.
OpenIn sheetjson1 tag match
Do not use trailing commas
Trailing commas make JSON invalid.
OpenIn sheetjson1 tag match