Why it matters
JSONPath picks values out of JSON: the price of every book, the IDs of failed jobs, the third item of a list. It's used in API tests, Kubernetes kubectl, AWS Step Functions and many monitoring tools, but each tool used to implement it slightly differently.
RFC 9535 (2024) finally standardised it. This tester follows the standard exactly, with filter expressions and functions, and shows the normalised path of every match, so you can paste the query into your own code knowing what it will return.
How it works
- InputJSON and a JSONPath query
- In your browserRun with the RFC 9535 rules
- OutputMatches, their paths and the result as JSON
Where it fits in a designer's workflow
- Plan
- Design
- Build
- Test
- Launch
By the numbers
Show the numbers as a table
| Query | Expression | Matches |
|---|---|---|
| Every product name | $.store.products[*].name | 4 |
| Every price, at any depth | $..price | 4 |
| Out of stock | $.store.products[?@.stock == 0].sku | 1 |
| In stock under £300 | $.store.products[?@.price < 300 && @.stock > 0].name | 2 |
| Has a finish | $.store.products[?@.finish] | 1 |
| Last product | $.store.products[-1:] | 1 |
| SKUs starting OAK- | $.store.products[?match(@.sku, 'OAK-.*')].price | 2 |
| More than one tag | $.store.products[?length(@.tags) > 1].name | 1 |
How to use it
- Paste your JSON.
- Type a query starting with $, or choose an example.
- Read the matches and their paths.
- Copy the result as JSON.
FAQ
Is this the same as jq?
No. jq is a full language with its own syntax. JSONPath only selects values, and is what many APIs and test tools accept.
How do filters work?
?(@.price < 10) keeps array items whose price is under 10. Combine conditions with &&, || and !.
What's a normalised path?
A unique path to one value, like $['store']['book'][0]['title'], useful for pointing at exactly that value.
Why does my old query fail?
Some older libraries allowed script expressions or different quoting. RFC 9535 is stricter; the error explains what to change.