jq Playground (Run jq Filters Online)

Test jq filters against your JSON without installing anything. Paste JSON, type a filter like .users | map(.name), and run it — this is the real jq command-line processor compiled to WebAssembly, so pipes, select, map, group_by, @csv, string interpolation and the standard flags (-r, -c, -s, -S, -n) all behave exactly as they do in your terminal. The engine loads on your first run and everything executes locally; your JSON is never uploaded.

How to use the jq Playground (Run jq Filters Online)

Paste your JSON into the Input box and type a filter in the field at the top. The simplest filter is ., which echoes the input (and pretty-prints it). From there you build up: .name reads a field, .items[] iterates an array, map(.id) transforms every element, select(.active) keeps matching items, and the pipe | chains steps together — for example .users | map(select(.age > 30)) | sort_by(.age). Press Run jq or hit Ctrl/Cmd+Enter. On the first run the jq engine (a ~2.7 MB WebAssembly build) downloads once and is then cached for the rest of your session.

The checkboxes map directly to jq's command-line flags. -r emits raw strings without JSON quotes (handy when your filter produces text); -c prints each result compactly on one line; -S sorts object keys; -s "slurps" a stream of inputs into a single array before filtering; -n starts from null input so you can generate JSON from scratch; and --tab indents with tabs. Output appears below exactly as jq would print it to stdout — including multiple results on separate lines — and you can copy it or download it as a file. Because this is the genuine jq, anything you prototype here works unchanged when you paste the same filter into jq on the command line.

What is jq, and why run it in the browser?

jq is a small, fast command-line program for slicing, filtering, mapping and transforming JSON. It has become the de-facto standard for working with JSON on the terminal — piping API responses through jq to pull out the fields you care about, reshape records, or convert JSON to CSV is a daily habit for most developers and ops engineers. Its power comes from a concise functional language built around the pipe: data flows left to right through a chain of expressions, each transforming the stream, much like Unix pipes but for structured data instead of lines of text.

That expressiveness is also why jq has a learning curve. The difference between .[] and .[]?, when to use map versus map_values, how group_by and reduce combine, what --slurp actually does to your input stream — these are far easier to learn by experiment than by reading the manual. A playground where you can paste real data, try a filter, and see the exact output instantly turns that trial-and-error loop from seconds-with-a-terminal into something you can do anywhere, including on a machine where jq isn't installed.

This playground runs the genuine jq — the same C program, compiled to WebAssembly — not a JavaScript reimplementation that approximates the syntax. That distinction matters: edge cases around number precision, error semantics, the @csv and @base64 formatters, regular-expression functions and the exact ordering of stream outputs all behave identically to the binary you'd install with brew install jq or apt install jq. Everything executes inside your browser tab, so your JSON — which is often an API response containing real, sometimes sensitive data — never leaves your machine. You get the convenience of an online tool with the fidelity and privacy of the real command-line program.

Common use cases

  • Learn and practise jq. Experiment with pipes, select, map, reduce and group_by against your own data and see results instantly.
  • Prototype a filter before scripting. Nail down the exact filter here, then paste it straight into a shell pipeline or CI script — it behaves identically.
  • Reshape an API response. Pull out the few fields you need, flatten nested objects, or rename keys without writing throwaway code.
  • Convert JSON to CSV or text. Use @csv, @tsv or string interpolation with -r to turn records into rows for a spreadsheet or report.

Frequently asked questions

Is this the real jq or a reimplementation?

It is the real jq — the original C program compiled to WebAssembly via the jq-web project. The language, built-in functions, formatters and error behaviour are identical to the jq binary you install on the command line, so any filter that works here works unchanged in your terminal.

Is my JSON uploaded anywhere?

No. The jq engine runs entirely in your browser through WebAssembly, and your JSON is passed to it locally. Nothing is sent to a server, which you can verify in your browser's Network tab — after the one-time engine download, running a filter produces no further network requests. That makes it safe for sensitive API responses.

Why is there a short delay on the first run?

The jq engine is a WebAssembly module of roughly 2.7 MB. To keep the page fast it is not loaded until you run your first filter, so the initial run includes a one-time download and compile. After that the engine stays in memory for the session and subsequent runs are instant.

What do the flag checkboxes do?

They pass jq's standard command-line options: -r outputs raw strings without quotes, -c prints compact single-line results, -S sorts object keys, -s (slurp) reads the whole input into one array first, -n uses null as the input so you can build JSON from scratch, and --tab indents with tabs. They combine exactly as they would on the command line.

How do I see the error when my filter is wrong?

If jq exits with an error — a syntax error in the filter, or a type error at runtime — the tool shows jq's own error message (the same text it prints to stderr) instead of output. Fix the filter and run again; nothing is cached between runs, so each run is evaluated fresh.
Embed this tool on your site

Free to embed, no attribution required (but appreciated). Paste this where you want the tool to appear: