# JSON Schema Tools

> JSON Schema Tools is an open-source MCP server for developer tools. Validate JSON against a schema with Ajv, infer schemas from samples and diff two schemas. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, Linux, macOS, Windows
- **Website:** https://basitalisandhu.github.io/dev-mcp-servers/
- **Repository:** https://github.com/basitalisandhu/dev-mcp-servers/tree/HEAD/packages/json-schema-tools
- **MCP Registry name:** io.github.basitalisandhu/mcp-json-schema-tools
- **Categories:** developer tools
- **Listing updated:** 2026-11-14

## About

The diff tool is the distinctive piece: it lists every change between two schemas with its path, old and new values and an impact of breaking, compatible or review, judged from the point of view of documents that were valid under the earlier schema. That helps when deciding whether an API contract change will break consumers.

Validation supports JSON Schema drafts 07, 2019-09 and 2020-12 through Ajv, checks formats such as email, uri, date-time and uuid, and returns up to 200 errors with JSON Pointer paths. Schema inference builds a draft 2020-12 schema from sample documents, with unioned types, required keys present in every sample and optional enums. Draft-04 and draft-06 schemas are rejected, and Ajv runs non-strict so unknown keywords do not fail.

It makes no network requests, so remote $ref targets are not fetched, reads no files, and caps schemas and documents at 2 MB. It ships as a pinned Docker image over stdio, MIT licensed.

## Features

- **Ajv validation:** Checks data against drafts 07, 2019-09 and 2020-12.
- **Schema inference:** Builds a 2020-12 schema from sample documents.
- **Schema diff:** Classifies each change as breaking, compatible or review.
- **Detailed errors:** Returns pointer path, keyword and message for up to 200 errors.
- **Format checks:** Validates email, uri, date-time, uuid and more.
- **No network or files:** Remote refs are not fetched; nothing is read from disk.

## Good for

- Generate a first schema from example API responses
- Check whether a schema change breaks existing documents
- Find which field fails validation in a payload
- Review a schema pull request for compatibility

## Install

### Claude Code (Terminal)

```sh
claude mcp add mcp-json-schema-tools -- docker run -i --rm ghcr.io/basitalisandhu/mcp-json-schema-tools:0.3.0
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "mcp-json-schema-tools": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-json-schema-tools:0.3.0"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "mcp-json-schema-tools": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-json-schema-tools:0.3.0"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "mcp-json-schema-tools": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-json-schema-tools:0.3.0"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "mcp-json-schema-tools": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-json-schema-tools:0.3.0"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "mcp-json-schema-tools": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-json-schema-tools:0.3.0"
      ]
    }
  }
}
```

## Tools

- `validate_json`: Validate data against a schema.
- `infer_schema`: Infer a schema from samples.
- `diff_schemas`: Diff two schemas with impact per change.

## FAQ

### Which drafts are supported?

Draft 07, 2019-09 and 2020-12; draft-04 and draft-06 are rejected.

### Does it fetch remote $ref schemas?

No. The README says remote $ref targets are not fetched.

### What size limits apply?

Schemas and documents are capped at 2 MB.

### How is it run?

As a pinned Docker image over stdio.

### Is JSON Schema Tools free?

Yes. JSON Schema Tools is open source, so you can use and self-host it for free.

### How do I add JSON Schema Tools to Claude Code?

Run this command in your terminal: claude mcp add mcp-json-schema-tools -- docker run -i --rm ghcr.io/basitalisandhu/mcp-json-schema-tools:0.3.0

### What are the best alternatives to JSON Schema Tools?

The closest alternatives to JSON Schema Tools are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.
- [Ouroboros](https://ai-powered.com/mcp/ouroboros): Ouroboros is an open-source MCP server for developer tools.
- [Claude Code Ultimate Guide](https://ai-powered.com/mcp/claude-code-ultimate-guide): Claude Code Ultimate Guide is an open-source MCP server for ai models and llm tooling.
- [Concord MCP](https://ai-powered.com/mcp/concord-mcp): Concord MCP is a freemium MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/json-schema-tools
