What is JSONPath and why use it?#
JSONPath is a query language for JSON, similar to XPath for XML. It lets you navigate and extract data from deeply nested JSON structures with concise expressions. JSONPath is widely used in APIs, test automation, data pipelines, and configuration systems.
How the click-to-build approach works#
The tree renders your JSON in a familiar collapsible structure. Each key or index is a clickable element. When you click one, the tool appends the corresponding JSONPath segment to the current expression — dot notation for simple keys ($.store), bracket notation for keys with special characters ($["my key"]), and index brackets for arrays ($.books[0]).
The Results panel on the right runs the JSONPath expression against your JSON in real time and shows the matched value or values, letting you iterate quickly until you find the exact path you need.
Understanding the quick reference expressions#
$ — The root of the document. Every JSONPath string starts with this.
**$.*** — Wildcard: selects all immediate children of the current node (all keys of an object or all elements of an array).
$.. — Deep scan (recursive descent): searches for the rest of the path at every level of the tree.
$[0] — Array index access: the first element (0-based).
$[-1:] — Slice syntax: the last element.
$[0:3] — Slice: the first three elements (indices 0, 1, 2).
$[?(@.price<10)] — Filter expression: an object that matches the condition (price less than 10). The @ refers to the current node being evaluated.