What JSON serialize means here
Serialization is the step that turns in-memory data into a sequence of bytes you can send or store. For JSON, that sequence is the text itself, written without any optional whitespace. This JSON serialize tool parses your document and writes it back in exactly that form, the same output a program produces with JSON.stringify(value) before putting it on a socket, in a queue or in a cache.
Example
A pretty-printed document with some unusual number notation:
{
"sku": "A-1",
"price": 10.50,
"qty": 1e2,
"tags": [ "new" ]
}
Serialized, with the status bar reporting "Serialized 51 B":
{"sku":"A-1","price":10.5,"qty":100,"tags":["new"]}
Two things happened beyond removing whitespace. Numbers are written in their shortest form, so 10.50 becomes 10.5 and 1e2 becomes 100. Escapes that are not required, such as a \u00e9 sequence for é, are replaced by the character itself. The data is unchanged; only its spelling is normalized, which is what a real serializer does after parsing.
Wrap as escaped string literal
Some formats carry JSON inside a string field: an event envelope with a "payload" property, a job queue that stores arguments as text, or a database column read by an ORM as a string. Tick Wrap as escaped string literal and the compact JSON is serialized a second time:
"{\"sku\":\"A-1\",\"price\":10.5,\"qty\":100,\"tags\":[\"new\"]}"
That value can be pasted as-is into another JSON document. The size in the status bar grows accordingly (65 B here) because each quote now needs a backslash.
Why check the size?
Many transports have hard limits on message size, and the limit is counted in bytes, not characters. The size shown is the UTF-8 byte length of the output, so accented letters and emoji count as two to four bytes each. Comparing it with the limit of your queue, cookie or header before sending saves a round of debugging.
What serialization does not do
- Key order is preserved as written; keys are not sorted. Use the JSON sorter first if you need a stable order for hashing or diffs.
- Invalid JSON is rejected with a line and column, since there is nothing to serialize. Repair it before serializing.
- Large integers above 253 are rounded by the parser. Send 64-bit IDs as strings.
To reverse the process, paste the output into JSON Deserialize. For a readable one-line form with spaces, see JSON to One Line.
Everything runs in the browser, and your payload is not uploaded unless you use Load URL or Save & Share.