JSONPath Query Tester
Run JSONPath expressions against JSON data and see all matches.
[ "Clean Code", "Pragmatic Programmer" ]
Quick Examples
Test JSONPath expressions online
This JSONPath tester runs a JSONPath expression against your JSON and lists every value it matches. Results update as you type, so you can check a path before you use it in code, an API test or a config file.
How to use it
- Paste your JSON into the JSON Input box. A sample bookstore document is loaded to start.
- Type a path in the JSONPath Expression field. It must start with
$. - See the match count and the matched values below.
- Click Copy JSON to copy the results as a JSON array.
- Click one of the Quick Examples to try a ready-made path.
Supported syntax
| Syntax | Meaning | Example |
|---|---|---|
$ | The root of the document | $ |
.key | A child property | $.store.owner |
['key'] | A property in brackets, useful for keys with spaces | $['first name'] |
[n] | An array item by index, starting at 0 | $.store.books[0].price |
[*] | Every item of an array or object | $.store.books[*].title |
..key | Recursive search for a key at any depth | $.store..author |
How it works
The tool parses your JSON, splits the path into steps and walks the data one step at a time. A wildcard step fans out to every child. A recursive step searches the whole subtree for the key. Each value found at the end of the path is one match. Everything runs in your browser.
Limits
- Filter expressions such as
[?(@.price > 40)]are not supported and return no matches. - Slices like
[0:2], negative indexes like[-1]and the.*form are not supported. Use[*]for a wildcard. - If the JSON is not valid, you see an "Invalid JSON input" message instead of results.
Frequently asked questions
What is JSONPath?
JSONPath is a query language for JSON, similar to XPath for XML. A path such as $.store.books[0].title points to one value inside a document.
Why do I get zero matches?
Check that the path starts with $, that key names match exactly (they are case-sensitive) and that you do not use filters or slices.
Is my JSON sent to a server?
No. The JSON is parsed and queried in your browser, so it is safe to test with private data.
Related Developer Tools
Browse all tools from the same category.
Domain Authority Checker
Check Moz authority, page authority, spam score, and backlink metrics
Open toolSEO Audit Tool
Audit a website URL for technical SEO, metadata, headings, broken internal links, hreflang, canonical and X-Robots-Tag checks, with report exports
Open toolShowing 1-2 of 48