Skip to content
Yunedia Tools

JSON Schema 驗證器

使用 Ajv 根據 JSON Schema 驗證 JSON 資料,並列出每一處違規及其路徑。完全在你的瀏覽器中運行。

使用方法

Put a JSON Schema in the first editor and the JSON data to check in the second, then press Validate. Validation uses Ajv with all-errors reporting: every mismatch is listed with its path (for example /age) and message. The Person and Product example buttons load ready-made pairs — try changing the data values to see errors appear. If the schema itself is invalid against the draft meta-schema, that is reported too.

注意事項

Everything runs locally; neither the schema nor the data leaves your browser. Note that format assertions such as format: "email" are treated as annotations by Ajv's default build (ajv-formats is not bundled), so they are not enforced — use pattern if you need to check a format here.

常見問題

Which JSON Schema draft is supported?

Ajv's default, draft-07. Schemas declaring draft 2019-09 or later may behave differently.

Why do I only see one error?

All-errors reporting is enabled, so validation errors are all listed. The exception is a schema that fails to compile — that stops the process earlier.