Paste JSON, click the value you want, get the jq expression that extracts it - the reverse of every jq playground.
Live at jq-pointer.jishnuteegala.com.
If you searched "jq path for a nested value", "jq expression to extract this field", or "how do I write a jq filter for this JSON", this tool is for you. Every jq playground works forwards: write an expression, check what it matches. jq-pointer works backwards: point at the value, get the expression.
- Paste JSON (or NDJSON log output) into the box, or drop a file onto it.
- Click a value to get its path:
.items[0].name. - Click the counterpart in a sibling array element and the path generalises:
.items[].name. - Click other keys of the same element and the output becomes an object construction:
.items[] | {name, id}. - Copy puts the jq expression on the clipboard:
.items[].name. On NDJSON input the buttons offer shell-ready invocations instead - per-linejq '<expression>'and slurpedjq -sforms. - Paste an expression into the highlight box to see every node it matches.
Everything runs in the browser: no accounts, no analytics, no third-party requests, and the document never appears in the URL.
The llms.txt at the repository root - also served at /llms.txt - describes the interaction model for agents.
The emitted expressions are ordinary jq that paste straight into a shell invocation:
echo '{"items":[{"name":"a"},{"name":"b"}]}' | jq '.items[].name'CI checks emitted syntax against pinned jq 1.6, 1.7.1, and 1.8.1 binaries (see "jq oracle" below), so the emitted expression behaves the same under real jq as it does in the tree.
Requires Node 20.19+ (or 22.12+) and pnpm.
pnpm install
pnpm dev| Command | What it does |
|---|---|
pnpm dev |
Start the dev server |
pnpm build |
Type-check and build the static bundle |
pnpm lint |
Run oxlint |
pnpm format |
Check formatting with oxfmt |
pnpm format:write |
Format the tree with oxfmt |
pnpm typecheck |
Run the TypeScript compiler |
pnpm test |
Run the test suite (includes the perf spike) |
pnpm bench |
Run only the performance spike |
pnpm preview |
Serve the built bundle locally |
pnpm check |
lint + format + typecheck + test |
pnpm check:privacy |
Scan dist for third-party requests |
Parsing is strict JSON.parse only - there is no tolerant repair.
Invalid input shows a positioned error with a caret excerpt of the offending line.
NDJSON is detected automatically when at least 90% of two or more non-empty lines parse; each valid record is navigable and malformed lines remain visible as errors.
The 10MB input cap applies to JSON and NDJSON alike.
JavaScript-literal pastes (trailing commas, single quotes, unquoted keys) are named in the error message without any repair.
Two JSON.parse behaviours are inherited deliberately and produce no warning:
- Duplicate keys: the last occurrence wins (
{"a": 1, "a": 2}parses as{"a": 2}). - Number precision: numbers beyond IEEE 754 double precision lose precision (
9007199254740993parses as9007199254740992).
The spike result and the main-thread vs worker decision are documented in docs/perf-spike.md.
Grammar and copied-invocation property tests run against pinned official Linux AMD64 binaries for jq 1.6, jq 1.7.1, and jq 1.8.1.
CI downloads them as jq-1.6, jq-1.7.1, and jq-1.8.1; these oracle and shell-round-trip tests skip on Windows because the binaries cannot execute locally.
The platform-independent conformance suite checks the parser/evaluator's accepted slice of jq's official tests/jq.test.
Emitted commands are validated against every supported jq version.
Deploy from a tagged release, not an arbitrary commit.
Every GitHub Release carries a prebuilt static dist archive (jq-pointer-<version>.zip and .tar.gz) plus a SHA256SUMS file.
VERSION=0.1.0
curl -fLO "https://github.com/jishnuteegala/jq-pointer/releases/download/v$VERSION/jq-pointer-$VERSION.tar.gz"
curl -fLO "https://github.com/jishnuteegala/jq-pointer/releases/download/v$VERSION/SHA256SUMS"
sha256sum --check --ignore-missing SHA256SUMS
mkdir -p dist && tar -xzf "jq-pointer-$VERSION.tar.gz" -C distThe app is a single static page plus real static routes (/design-system/, /llms.txt); any static file server works with no rewrite rules required.
Cloudflare Pages
pnpm dlx wrangler pages deploy dist --project-name jq-pointerOr use git integration: import the repo in the Cloudflare dashboard with build command pnpm build and output directory dist.
The bundled _headers file sets the security headers automatically.
Vercel
pnpm dlx vercel deploy dist --prodNetlify
pnpm dlx netlify-cli deploy --dir dist --prodOr drag-and-drop the dist folder onto the Netlify dashboard's deploy area.
Netlify reads the bundled _headers file too and applies the security headers; the Cloudflare-specific ! Header detach lines in it are ignored there.
GitHub Pages
git checkout --orphan gh-pages && git rm -rf . && cp -r dist/. . && rm -rf dist
git add -A && git commit -m "deploy" && git push -f origin gh-pagesThen enable Pages for the gh-pages branch in the repo settings.
VPS with nginx (any cloud - AWS/GCP/Azure/other)
server {
listen 80;
server_name jq.example.com;
root /var/www/jq-pointer;
index index.html;
location /assets/ {
add_header Cache-Control "public, max-age=31536000, immutable";
}
}Copy the extracted dist/ to /var/www/jq-pointer and reload nginx.
VPS with Caddy
jq.example.com {
root * /var/www/jq-pointer
file_server
}Docker
FROM nginx:alpine
COPY dist /usr/share/nginx/html
EXPOSE 80docker build -t jq-pointer . && docker run -p 8080:80 jq-pointerOr with compose, no image build needed:
services:
jq-pointer:
image: nginx:alpine
volumes:
- ./dist:/usr/share/nginx/html:ro
ports:
- "8080:80"Releases are managed by release-please: merging the release PR tags the version, and the release stays a draft until the dist archives are built, checksummed, and uploaded.
MIT - see LICENSE