JSONPath Tester

Test JSONPath expressions

What Is This Tool?

The JSONPath Tester lets you evaluate a JSONPath-style expression against a JSON document and instantly see the matched value or values. It's useful for exploring API responses, building path expressions for scripts or configuration, and confirming an expression selects exactly what you expect before wiring it into code. Everything runs locally in your browser.

How to Use

1

Paste your JSON document into the data box.

2

Enter a JSONPath expression, such as $.items[0].name.

3

Click Evaluate to see the matched value(s) as JSON.

Features

  • Root $, dot .key, and bracket ['key'] property access
  • Array indexing with [n]
  • Wildcard [*] over array elements or object values
  • Recursive descent with ..key
  • Clear distinction between "no match" and a malformed expression
  • 100% client-side — nothing leaves your browser

Examples

JSON:

{
  "items": [
    { "name": "Widget", "price": 9.99 },
    { "name": "Gadget", "price": 19.99 }
  ]
}

Expression: $.items[0].name

Result:

"Widget"

Wildcard expression: $.items[*].name

["Widget", "Gadget"]

Common Use Cases

  • Exploring an unfamiliar API response to find the right field
  • Building and testing a path expression before using it in code
  • Extracting a single value or a list of values from nested JSON
  • Debugging why an existing JSONPath expression isn't matching anything

Frequently Asked Questions

What JSONPath syntax is supported?

The root $, dot property access like .key, bracket property access like ['key'], array indexing with [n], the wildcard [*] over array elements or object values, and recursive descent with ..key.

Are filter expressions like [?(@.price < 10)] supported?

No. This is a small hand-rolled subset of JSONPath for common lookups. Filter expressions, script expressions, and slice syntax ([1:3]) are out of scope and will report as an unsupported/malformed expression.

What's the difference between "no match" and an invalid expression?

A syntactically valid expression that simply doesn't find any matching data (for example, a key that doesn't exist) reports "No match found." A malformed expression, such as mismatched brackets, reports a specific parsing error instead.

How does ..key recursive descent work?

It searches every level of the document for a property named key and returns all matches found, regardless of how deeply nested they are.

Does it show one match or all matches?

If exactly one value matches, it's shown directly. If multiple values match (for example via a wildcard or recursive descent), they're shown together as a JSON array.

Is my JSON data uploaded anywhere?

No. Parsing and evaluation happen entirely in your browser using JavaScript. Nothing is sent to a server.

Can I copy the result?

Yes, click Copy to copy the matched result as JSON text to your clipboard.