JSONPath Finder
Paste JSON and get every path in it listed in dot or bracket notation, with a depth limit and a filter.
Click any path to copy it.
Enumerate every path in a JSON document so you can find the one you need without counting brackets. Paths are shown in dot or bracket notation, the depth can be limited, and a filter narrows a long list to the keys you care about.
JSONPath Finder: Features
The problem it solves
You have an API response and you need the path to one value: the expiry inside the third element of a nested array, or the identifier buried four levels down. Reading it off the formatted JSON means counting brackets and keeping track of which array index you are in, which is exactly the sort of task where a small mistake costs ten minutes. Listing every path turns that into a search.
Dot and bracket notation
Dot notation is compact and reads well for ordinary keys. Bracket notation is necessary when a key contains a space, a hyphen, a dot or anything else that would break the dot form, and some tools accept only one of the two. Being able to switch means you can produce the form your target expects rather than translating by hand. Array indices appear in brackets in both modes, because there is no alternative.
Depth limiting and filtering
A large response can produce thousands of paths, most of which are not what you are looking for. Limiting the depth keeps the list to the upper levels of the structure, which is the right view when you are orienting yourself rather than hunting a specific leaf. The filter narrows the list to paths matching what you type, which is the right view when you know roughly what the key is called. Together they make a large document tractable.
JSONPath, JMESPath and jq are not the same
All three extract values from JSON and all three use different syntax, which is a common source of confusion. The paths produced here follow the JSONPath convention, which is what Postman assertions, many API documentation tools and a wide range of libraries expect. jq uses a leading dot and no dollar sign, so dropping the dollar gives you something close. JMESPath differs more substantially, particularly around filters and projections.
Exploring a production response safely
The document is parsed and walked in your browser, and nothing is transmitted, stored or logged. Production API responses, records containing personal data and payloads captured during an incident can all be explored here. Click any path to copy it, or copy the whole list at once. To reformat the same document, the JSON Formatter is a click away. To compare two responses instead of exploring one, use the JSON Diff.
JSONPath Finder: FAQ
How do I convert a path for jq?
Drop the leading dollar sign. A JSONPath of the form with a dollar followed by dot user dot name becomes dot user dot name in jq. Array indices carry over unchanged. The two syntaxes diverge once you use filters or wildcards, so this shortcut applies to plain paths.
How are array elements shown?
With their numeric index in brackets, counting from zero. Every element of an array gets its own path, so an array of fifty objects produces fifty sets of paths. Limiting the depth is the usual way to keep that manageable while you orient yourself.
Does it evaluate a path against the document?
No, it works the other way round: it enumerates the paths that exist rather than resolving one you supply. That is deliberate, because the common problem is not knowing what the path should be. Once you have it, evaluate it in whatever tool will consume it.
How large a JSON document can it walk?
Reasonably large ones, though every path is rendered into the page, so a document with tens of thousands of leaves becomes slow. Limiting the depth helps considerably. For genuinely large files a command line tool such as jq is the better instrument.
How to Use JSONPath Finder
-
Paste the JSON to explore
Put the document into the input box, or press Sample to load a small worked example. The path list is built as soon as the document parses.
-
Choose notation and depth
Select dot or bracket notation to match whatever will consume the path, and set a depth limit if the document is large enough that the full list is unwieldy.
-
Filter, then copy the path you need
Type part of a key name into the filter to narrow the list, then click a path to copy it. Copy all takes the whole visible list at once, which is useful when documenting a response.
Category Data Formats