YAML/JSON Path Tester - JSONPath & YAML Path Expression Tester
Free online YAML and JSON Path tester. Test JSONPath and YAML path expressions in real-time with instant results. Perfect for Kubernetes configs, CI/CD pipelines, and API testing. 100% client-side processing.
Quick Examples (Click to Load)
$.store.book[*].author
Get all book authors$.store.book[?(@.price < 10)]
Books under $10spec.containers[*].image
Kubernetes container imagesmetadata.labels.app
Kubernetes app labelJSONPath Syntax Reference
$
Root element@
Current element (in filters). or []
Child operator*
Wildcard (all elements)[start:end]
Array slice[?(<expr>)]
Filter expressionWhat is JSONPath?#
JSONPath is a query language for JSON, similar to XPath for XML. It provides a way to extract specific data from a JSON document using path expressions. JSONPath is widely used in DevOps tools, CI/CD pipelines, and API testing.
Common JSONPath Operators#
| Operator | Description | Example |
|---|---|---|
$ | Root element | $ |
@ | Current element (in filters) | @.price |
. | Child operator | $.store.book |
[] | Subscript operator | $.store.book[0] |
* | Wildcard (all elements) | $.store.book[*] |
[start:end] | Array slice | $.store.book[0:2] |
[?()] | Filter expression | $.store.book[?(@.price < 10)] |
Common Use Cases#
Kubernetes Configuration#
JSONPath is built into kubectl for extracting data from resources:
| |
CI/CD Pipelines#
Extract values from configuration files:
| |
API Response Parsing#
Query API responses in tests or scripts:
| |
YAML Path Expressions#
YAML path expressions work similarly to JSONPath but are designed for YAML documents. Since YAML is a superset of JSON, you can use the same path syntax:
| |
Path expressions for this YAML:
metadata.name→my-podmetadata.labels.app→nginxspec.containers[*].image→["nginx:1.14.2"]
Filter Expressions#
Filter expressions allow you to select elements based on conditions:
| Expression | Description |
|---|---|
[?(@.price < 10)] | Elements where price is less than 10 |
[?(@.price > 20)] | Elements where price is greater than 20 |
[?(@.category == 'fiction')] | Elements where category equals ‘fiction’ |
[?(@.price != 8.95)] | Elements where price is not 8.95 |
Privacy & Security#
All processing happens directly in your browser:
- No Server Communication: Your JSON/YAML data never leaves your device
- No Storage: Nothing is saved to localStorage, cookies, or servers
- Open Source: All code is transparent and auditable
Related Tools#
Explore our other DevOps tools:
- kubectl Builder - Visual kubectl command builder
- Regex Lab - Test and debug regular expressions
- JWT Tools - Decode and create JSON Web Tokens
- SSL Tools - Certificate validation and key generation
