DecodeBox
Search
K
Guides
SDK Reference
Operations
Playgrounds
Operations Explorer
Auto Detection Lab
Encoding & Decoding Lab
Open DecodeBox
Theme
Menu
ON THIS PAGE
#
JSON Minify
Removes all optional whitespace from JSON.
ID:
json-minify
Category: Code tidy
Aliases: compact json, minify json
#
Arguments
Argument
Type
Default
Constraints
On invalid JSON
option
"Fail"
Fail, Strip whitespace anyway. A payload with a trailing comma is still worth compacting. Stripping does not validate.