JSONPath Tester
JSONPath 测试工具
对任意 JSON 文档运行 JSONPath 表达式,匹配结果实时高亮显示。
"Eloquent JavaScript"
"You Don't Know JS"
"Clean Code"
JSONPath Quick Reference
$Root element.Child operator..Recursive descent*Wildcard (all children)[n]Array index (negative ok)[start:end]Array slice[a,b]Union of indices/keys[*]All array elements[?(@.key)]Filter - key exists[?(@.key == val)]Filter - equality[?(@.num > val)]Filter - comparison使用方法 JSONPath 测试工具
- 1.粘贴您的 JSON 在输入面板输入要查询的 JSON 文档。
- 2.输入 JSONPath 表达式 在查询框输入 JSONPath 表达式,例如 $.users[*].email 或 $.store.book[?(@.price < 10)]。
- 3.查看结果 匹配的节点显示在结果面板,并在源 JSON 中高亮。
- 4.优化查询 调整表达式,结果会即时更新,直到拿到需要的数据。
JSONPath 测试工具 & JSON Developer Standards
JSON is the standard format for web APIs and modern applications. Using the JSONPath 测试工具 helps you check syntax, catch formatting errors, and keep your data clean and readable.
Zero-Server Security
All data entered into JSONPath 测试工具 runs directly inside your browser sandbox. Nothing is ever sent across the network or saved on remote servers.
Clean & CI/CD Ready
Well-formatted JSON prevents runtime syntax bugs, makes code reviews easier, and ensures smooth API data exchange.
JSONPath 测试工具 常见问题
什么是 JSONPath?
JSONPath 是 JSON 的查询语言,类似于 XML 的 XPath。它用路径表达式在 JSON 中导航并提取值,广泛用于 API、测试工具与配置系统。
支持哪些 JSONPath 语法?
本工具支持标准 JSONPath 操作符:$(根)、.(子节点)、..(递归下降)、*(通配符)、[n](数组下标)、[start:end](切片)、[?(expression)](过滤器)与 @(过滤器中的当前节点)。
$..price 返回什么?
.. 是递归下降操作符。$..price 返回文档中所有 key 为 'price' 的值,无论层级多深。
可以用过滤表达式吗?
可以。过滤表达式用 [?(@.property operator value)] 语法,例如 $.books[?(@.price < 20)] 返回所有 price 小于 20 的 book 对象。
结果是以 JSON 数组形式展示吗?
是。结果面板把匹配的值显示为 JSON 数组。单个值匹配时会显示为单元素数组,没有匹配则返回空数组。
Can this tool handle large, complex JSON payloads?
Yes. Because the tool operates directly inside modern V8 JavaScript execution engines, it easily processes complex multi-megabyte payloads containing thousands of nested keys with negligible latency.
Are my proprietary payloads or secrets stored or cached?
No. BeYourTools implements zero tracking, zero telemetries, and zero database persistence. Everything stays strictly inside your browser memory and disappears the moment your tab is closed.