JSON Duplicate Key Checker

JSON.parse silently keeps the last value when a key is repeated. The checker walks every object and tells you exactly where the duplicates live.

JSON Duplicate Key Finder

Detect duplicate keys that can cause data loss

Instant Scan

Detect duplicates in milliseconds

100% Private

All processing happens in your browser

No Signup

Free tool, no registration required

Frequently Asked Questions

Instant

Runs entirely in your browser — no upload, no wait.

100% private

Your JSON never leaves the tab. Nothing is logged.

No signup

Free, unlimited, no account required.

The silent JSON bug

JSON technically allows duplicate keys (the spec only says behavior is "implementation-defined"). Every mainstream parser keeps the last occurrence. The result: data loss with no warning. The checker scans your document and reports each duplicate with its full JSON Pointer path.

How duplicates sneak in

Most often via concatenation — merging two API responses, hand-editing a config, or copying a block of keys without noticing one of them already exists. Code generators occasionally emit duplicates when two source schemas map to the same JSON property.

Reading the report

Each row shows the offending key, the JSON Pointer to the parent object, the values that would be lost, and a quick action to keep the first or the last occurrence.

CI integration

For automated checks, ajv with allowUnionTypes: false and a custom keyword can flag duplicates at validation time. For raw text scanning, the snippet below is enough.

// Lossless reviver — collects duplicates instead of dropping them
const seen = [];
JSON.parse(input, function (key, value) {
  if (this && Object.prototype.hasOwnProperty.call(this, key) && seen.indexOf(this) === -1) {
    seen.push(this);
  }
  return value;
});

Privacy

All scanning happens in the browser. No upload, no telemetry.

Related tools

Frequently asked questions