JSONPath Query Playground
Test RFC 9535 JSONPath queries and see every match with its path
Paste JSON, open a file, or load an example.
RFC 9535 JSONPath, evaluated in your browser by jsonpath-rfc9535 1.3.0 in a background worker.
What is the JSONPath Query Playground?
A playground for RFC 9535 JSONPath, the IETF standard for selecting nodes in a JSON document. Paste JSON, write a query such as $.store.products[?@.price < 50].name and see every match with its value, its normalized path and its JSON Pointer. Use it to write selectors for API tests, configuration tools, OpenAPI overlays or Kubernetes-style tooling and to see exactly which nodes they select. To transform or reshape JSON, use the jq-based JSON Query Playground; to find keys or values by text, use JSON Search.
Supported syntax
The root $, member names ($.name and $['name']), array indices including negative ones ([0], [-1]), wildcards ([*] and .*), slices with an optional step ([1:5], [::-1]), several selectors in one bracket ([0,2] or ['a','b']), descendants (..name and ..*) and filters. Filters ([?…]) compare with == != < <= > >=, combine with && || ! and parentheses, and test existence with ?@.member: that test is true when the member exists, even if its value is false or null. The five RFC functions are available: length(), count(), match(), search() and value(). Each entry in Syntax examples loads a query for the Store catalog example.
Regular expressions in match() and search()
match() and search() take an I-Regexp pattern (RFC 9485), a small interoperable subset of regular expressions. match() must match the whole string, search() looks for the pattern anywhere in it. Unicode is on by default and the dot matches any character except line breaks. Backreferences, lookarounds, lazy quantifiers and flags are not part of I-Regexp; avoid them, because other JSONPath implementations reject or ignore them.
Normalized paths and JSON Pointers
Every match lists its normalized path, the canonical RFC 9535 form such as $['store']['products'][0]['name'], where apostrophes, backslashes and control characters in member names are escaped. It also lists the matching RFC 6901 JSON Pointer such as /store/products/0/name, where ~ becomes ~0 and / becomes ~1; the whole document is the empty pointer. Use the paths in tests and the pointers in JSON Patch operations or $ref values.
Limits and privacy
The query runs in a background worker in your browser; nothing is uploaded or stored, and only the selected result view is remembered. Inputs up to 256 KB re-run as you type; larger inputs up to 10 MB run when you press Run, and runs stop after 15 seconds. The list shows the first 2,000 matches while the count and Copy all actions include every match. This tool selects nodes only: it does not transform data. Older non-standard extensions such as script expressions or the ~ key operator are rejected as syntax errors, and @.length reads a member named length (use length(@) for the size). Numbers beyond JavaScript precision are shown as the nearest representable value.
