Unstructured Text
JSON Minifier
Compress JSON onto a single line by removing all unnecessary whitespace.
When to use it
Typical uses: Reducing API request and response sizes; Storing JSON in environment variables or a single database field; Embedding JSON in HTML or JavaScript.
In a pipeline
Text InputJSON MinifierText Output
Settings
| Setting | Type | Required | Default or hint |
|---|---|---|---|
| Text column | select | — | Text |
| Generate New Column | checkbox | — | false |
| New Column Name | text | — | Default: <column> Result |
| Insert After | select | — | After the column |
| When a value cannot be converted | select | — | stop |
Example
JSON Minifier: an example
| Text |
|---|
| { "id": 42, "title": "Hello world", "tags": [ "a", "b" ] } |
| Text |
|---|
| {"id":42,"title":"Hello world","tags":["a","b"]} |
Worth knowing
- How much smaller will my JSON be? It depends on the indentation. Heavily indented files often shrink by 20–40%.
- Are spaces inside strings removed? No. Only whitespace between tokens is removed.
- How do I make it readable again? Use the JSON Formatter.
- Works on any text column, not only Text Input's: pick it under Text column. Tick Generate New Column to keep the original next to the result.