Free tools Windows power users keep installed
One-click scans. No signup required.
iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more
JSONPath lets you select values from nested JSON with a query that starts at the root, $. Use child paths to reach a field, array indexes or slices to choose elements, wildcards to select broadly, and filters to keep only items that match a condition. The standard is RFC 9535, published by the IETF in February 2024; a particular tool may expose results differently or support a different subset, so check its documentation.
Start with a JSON value and a root query
JSONPath is a string syntax for selecting and extracting values from a JSON value. Every query begins with $, which identifies the root of the JSON being queried.
| # | Preview | Product | Price | |
|---|---|---|---|---|
| 1 |
|
The C Programming Language | $9.80 | Buy on Amazon |
| 2 |
|
The SQL Programming Language: . | $4.23 | Buy on Amazon |
These examples use the bookstore-shaped JSON data in RFC 9535. For example, $.store.book[0].title follows the root to the store object, then its book array, then the first array element, and finally that element’s title.
Dot notation is a convenient shorthand for common property names. Bracket notation is canonical in the standard; $['store']['book'][0]['title'] expresses the same path as the dot-notation example. Use quoted names in brackets when that form is clearer or needed for a property name that does not fit ordinary dot notation.
#1 Best Overall
Choose fields, array elements, or nested matches
JSONPath combines selectors to describe which nodes to select. The following examples show common building blocks:
| Task | Query | What it selects |
|---|---|---|
| Select one array element’s field | $.store.book[0].title |
The title of the first book. |
| Select a field from every array element | $.store.book[*].title |
The title values of all books. The wildcard * selects every child at that position. |
| Select a range of array elements | $.store.book[0:3].title |
Titles at indexes 0, 1, and 2. The slice’s end index is excluded. |
| Search below the current node | $..author |
Author values found below the root. The descendant segment .. searches at deeper levels. |
Array indexes are zero-based: [0] refers to the first element. If an index is outside the array’s range, it selects no node; it does not make the query fail.
Filter an array with a condition
A filter selector, written as [?(...)] in the standard’s general syntax, tests candidate children and selects those for which its logical expression matches. Inside a filter, @ refers to the current candidate node; $ continues to refer to the root of the query argument.
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →For example, $.store.book[?@.price < 10].title selects the title of each book whose price is less than 10. The filter checks each book, then the trailing .title selects that field from matching books.
Rank #2
- Used Book in Good Condition
RFC 9535 defines comparisons, logical operators, existence tests, and a standardized set of function extensions for filter expressions. Function extensions also provide a way for implementations to add functions, so a function supported by one tool may not be available in another.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Understand what a query returns
The standard describes a query result as a nodelist: zero or more selected nodes. An empty result is valid, such as when a filter matches nothing. The standard defines the required selection results, not how a library must present them; an API may return selected values, normalized paths, or both.
- Duplicates can remain. If a query selects the same node more than once, it appears that many times in the nodelist.
- Array order is meaningful. JSON arrays have ordered children, so selections from an array follow its order.
- Object-member order is unspecified. JSON objects are unordered, and RFC 9535 does not stipulate an order for selected object members. Do not rely on a consistent order when comparing such results.
Check an implementation before relying on a query
RFC 9535 standardizes JSONPath syntax and required query results while leaving internal implementation choices open. Before using a query in an application or workflow, check the documentation for the particular library or tool and confirm:
- Whether it supports the RFC 9535 syntax your query uses, including filters and slices.
- Which standardized filter functions it implements and whether it adds implementation-specific functions.
- Whether its API returns values, paths, or both.
- How it presents ordering and duplicate selections.
Do not assume that a tool supports every standardized feature simply because it accepts JSONPath queries. The RFC Editor maintains an errata report for RFC 9535; consult it if you need to check for corrections to the standard.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

