Embed this tool on your site
<iframe src="https://devtoolbox.dedyn.io/tools/json-path-extractor" width="100%" height="600" frameborder="0" title="JSON Path Extractor"></iframe>

JSON Path Extractor & Query Tool

Navigate JSON data and extract values using JSONPath queries. Click any key in the tree view to auto-generate its path. Everything runs in your browser.

Recent:
 
Enter a JSONPath query and click "Extract" or press Ctrl+Enter.

JSONPath Syntax Reference

JSONPath expressions always start with $ representing the root object. Use the table below as a quick reference.

ExpressionDescriptionExample
$Root object$ returns the entire document
.keyDot notation child$.store.name
['key']Bracket notation child$['store']['name']
[0]Array index (0-based)$.store.books[0]
[-1]Last array element$.store.books[-1]
[*]Wildcard (all elements)$.store.books[*].title
[0:2]Array slice$.store.books[0:2]

Related Reading

The Complete Guide to JSON — Learn everything about JSON syntax, data types, best practices, and common pitfalls.

Frequently Asked Questions

What is JSONPath and how does it work?
JSONPath is a query language for JSON, similar to XPath for XML. It uses expressions like $.store.books[0].title to navigate nested JSON structures and extract specific values. The $ symbol represents the root object, dots navigate into nested keys, and brackets access array elements or use wildcards.
What is the difference between dot notation and bracket notation in JSONPath?
Dot notation ($.store.name) is the simpler, more readable syntax for accessing keys with standard names. Bracket notation ($['store']['name']) is required when keys contain special characters, spaces, or hyphens. Both produce the same result for standard key names.
How do I extract all values from a JSON array using JSONPath?
Use the wildcard operator [*] to extract all elements from an array. For example, $.users[*].name extracts the name field from every object in the users array. You can also use specific indices like $.users[0] for the first element or $.users[-1] for the last element.
Keyboard Shortcuts
Ctrl+Enter Run query
Ctrl+Shift+C Copy result
Ctrl+L Clear