JSONPath Tester

Test and evaluate JSONPath expressions against JSON data instantly in your browser. Powered by jsonpath-plus.

Enter JSON and a JSONPath expression

Or click to get started

Sample Expressions (click to try)

About the JSONPath Tester

The JSONPath Tester lets you write and evaluate JSONPath expressions against any JSON document in real time. Paste your JSON, type an expression, and see matched nodes instantly — no page reload, no server round-trip.

This tool is powered by jsonpath-plus, a feature-complete JSONPath library that supports the full JSONPath specification including recursive descent (..), wildcard (*), array slices, union operators, and filter expressions with script predicates.

JSONPath Syntax Cheatsheet

SyntaxMeaningExample
$Root element$
.keyChild property$.store.name
['key']Child property (bracket notation)$['store']['name']
*Wildcard — all children$.store.*
..Recursive descent$..price
[n]Array index (0-based)$.store.book[0]
[start:end]Array slice$.store.book[0:2]
[a,b]Union — multiple indices or keys$.store.book[0,2]
[-1]Last element$.store.book[-1]
[?(@.key)]Filter — existence check$.store.book[?(@.isbn)]
[?(@.key op val)]Filter — comparison$.store.book[?(@.price < 10)]

How to Use the JSONPath Tester

  1. Paste your JSON into the JSON Input textarea, or click Sample JSON to load a bookstore example.
  2. Type a JSONPath expression into the Expression field above the input area.
  3. Matched nodes appear immediately in the Result panel on the right — no button click required.
  4. Use the Sample Expressions grid to quickly apply common queries to the loaded JSON.
  5. Click Copy to copy the result JSON to your clipboard.

Frequently Asked Questions

What is JSONPath?

JSONPath is a query language for JSON, similar to XPath for XML. It lets you extract specific values from deeply nested JSON structures using a concise expression syntax. It was originally proposed by Stefan Goessner in 2007 and has since become a widely used standard for querying JSON data in APIs, databases, and developer tooling.

What library powers this tool?

This tester uses jsonpath-plus, an actively maintained JavaScript implementation that extends the original JSONPath specification with additional features including type filters, parent axis, and improved filter expression support.

Why does my filter expression return no results?

Filter expressions are case-sensitive and require exact type matching. Make sure string values are quoted (e.g. @.category == "fiction") and numeric comparisons use unquoted numbers (e.g. @.price < 10). The @ symbol always refers to the current node being tested.

Is my data sent to a server?

No. All evaluation happens entirely in your browser. Your JSON data never leaves your device, making this tool safe for confidential payloads, API responses, and internal data structures.

What does recursive descent (..) do?

The .. operator searches at every depth level of the document. For example, $..price returns every price field found anywhere in the JSON, regardless of how deeply nested it is.

How do I select the last item in an array?

Use a negative index: $.store.book[-1] returns the last book. [-2] returns the second-to-last, and so on.