JSONPath Tester
Paste a JSON document on the left and type a query such as $.store.book[?@.price < 10].title on the right. Each match appears with its normalized path. A syntax error points at the place in the query where the parser stopped.
JSONPath Tester runs entirely in your browser: the text you paste is never sent to a server. It is free and needs no sign-up.
How to use it
- Paste a JSON document Paste up to 2 MB of JSON into the left box. A syntax error shows its line and column, and the query waits until the JSON is valid.
- Write a query Type a query that starts with $, such as $.store.book[*].author. Use .name, [index], [*], slices, filters such as [?@.price<10] and ..name. Results update as you type.
- Read the matches Each match shows its normalized path, such as $['store']['book'][2], and its value. Copy one path, or copy all values as a JSON array. The table shows at most 500 rows.
Questions
Which JSONPath syntax does the tester support?
It follows RFC 9535, with filters that use && and || and comparisons, the functions length, count, match, search and value, and slices with negative steps. The older forms [(@.length-1)] and =~ are not supported, so write [-1] or match() instead.
Why does a query stop or show a limit message?
A query runs in a background thread and stops after 3 seconds. The search stops after 1,000,000 visited nodes, and only the first 10,000 matches are returned. Documents nested deeper than 500 levels are refused.
Are the regex functions the same as JavaScript regular expressions?
match() and search() convert the pattern to a JavaScript RegExp with the u flag. Backreferences and lookaround are rejected, and so are patterns longer than 200 characters. This is a subset of I-Regexp, not a full implementation. The tool never runs code.