ZeroTool Workbench
jq Playground
Run jq filters against JSON in your browser with the official jq 1.7 engine. Pipe, select, map, group_by, sort, reduce — no install, no upload, no signup.
How to Use
- Paste or type your JSON into the JSON Input panel (a sample users dataset is preloaded).
- Type a jq filter in the jq Filter field, or click one of the Example pills.
- Results render with JSON syntax highlighting under Result.
- Click Copy to copy the formatted output to your clipboard.
jq Cheat Sheet
.— the identity filter, returns the input unchanged.field— extract a property value.field?— extract optionally (no error when field is missing).[]— iterate over array or object values.[start:end]— array slicef | g— pipe output of f into gf, g— produce both f and g outputsselect(cond)— keep values where cond is truemap(f)— apply f to each element of an arraygroup_by(.k)— group an array by keysort_by(.k)— sort an array by keylength,keys,values,type,has(k)— introspectionadd,min,max,unique— aggregationtonumber,tostring,ascii_downcase,split(”/”)— conversionreduce,foreach,def— control flow and custom functions
Common Use Cases
jq is the standard tool for shell pipelines that touch JSON: API responses from curl, Kubernetes
manifests, CI/CD logs, AWS CLI output, infrastructure-as-code state, and analytics exports. This playground
is for prototyping a filter on a small sample before piping a giant file through the CLI — copy the filter
out and use it verbatim with jq -r ’…’.
Typical recipes: .items | map({id, name}) to flatten API list responses,
group_by(.tag) | map({tag: .[0].tag, count: length}) to bucket events,
[.[] | .duration_ms] | add / length to average a numeric field.
FAQ
Is this the real jq or a JavaScript reimplementation?
This is the official jq 1.7 C source compiled to WebAssembly via jq-web. Filter output matches the jq command-line tool byte-for-byte. The engine downloads once (about 1MB compressed) and is cached by your browser for every subsequent visit.
What jq features are supported?
Full jq 1.7 syntax — pipes, select, map, group_by, sort_by, reduce, foreach, try/catch, custom function definitions (def), recursive descent (..), string operations, math, date functions, and every built-in. If a filter works in the jq CLI, it works here.
Are my JSON and filter expression sent to a server?
No. The jq engine runs entirely in your browser via WebAssembly. Your JSON and filter never leave the device. Open DevTools → Network and you will see only the one-time jq.wasm download — no request payloads.
What is the maximum JSON size?
About 50MB is the practical ceiling — beyond that, browser memory and parsing time become noticeable. For multi-gigabyte JSON streams use the jq command-line tool with --stream.
How is this different from JSONPath Tester?
JSONPath is a path query language for picking nodes by location. jq is a full transformation language with pipes, conditionals, math, and function definitions. Use JSONPath Tester for simple lookups; use jq for shaping, filtering, aggregating, and reformatting JSON.