JSON Formatter vs Validator vs Tree Paths: Which Check Finds Which Problem?

May 27, 2026

Comparison

JSON Formatter vs Validator vs Tree Paths: Which Check Finds Which Problem?

6 min read

By Donald Leijon - Independent web developer and tool builder, based in Sweden.

A concrete payload example showing what formatting, parsing validation, and visible JSON paths each reveal - and what none can prove.

developer-toolsdebuggingcontent-workflows

Quick scan

  • Problem: "Validate the JSON" can mean three different tasks: read it, parse it, or inspect its fields.
  • Approach: Run one payload through formatting, validation, and tree-path inspection in JSON Format Studio.
  • What this verifies: JSON syntax and visible values in the pasted sample.
  • What this does not verify: Schema rules, API acceptance, data truth, or permission to use the payload.

Sample A: Valid JSON that is difficult to scan

Input:

{"requestId":"req_1042","operation":"deploy","status":"failed","errors":[{"code":"AUTH_MISSING","message":"missing token"}],"meta":{"retry":false,"attempt":1}}

Use Prettify when the problem is readability

Output:

{
  "requestId": "req_1042",
  "operation": "deploy",
  "status": "failed",
  "errors": [
    {
      "code": "AUTH_MISSING",
      "message": "missing token"
    }
  ],
  "meta": {
    "retry": false,
    "attempt": 1
  }
}

Found: the error is nested in an array and retry is false.

Not found: whether AUTH_MISSING is a permitted API error code or whether attempt 1 is accurate.

Sample B: Text that fails JSON parsing

Input:

{
  "requestId": "req_1042",
  "status": "failed",
  "retry": false,
}

The trailing comma after false is valid in some programming-language object literals, but not in JSON. Running Validate should return an error instead of a formatted result.

Found: the pasted text does not parse as JSON.

Not found: the intended correction. You still need to determine whether deleting the comma, adding a field, or retrieving a clean original is correct.

Sample C: Valid syntax with a suspicious value

Input:

{
  "requestId": "req_1042",
  "status": "accepted",
  "meta": {
    "retry": "false",
    "attempt": 1
  }
}

This parses as valid JSON, but "false" is a string rather than the boolean false.

Use Tree paths when the problem is shape and type inspection

After a successful transform, the visible paths include:

$.requestId        string   req_1042
$.status           string   accepted
$.meta              object  nested object
$.meta.retry        string   false
$.meta.attempt      number   1

Found: the sample contains a string where a reviewer may have expected a boolean.

Not found: whether the API schema permits strings. For that you need the contract or validation code.

Which button should you use?

| Question | Start with | It can reveal | It cannot prove | | --- | --- | --- | --- | | "I cannot read this one-line payload." | Prettify | Nested structure and readable values | That values are allowed | | "Is this pasted text legal JSON?" | Validate | Parse success or syntax failure | Schema compliance | | "Where is the odd value hiding?" | Tree paths after a transform | Early paths, types, and previews | Complete inspection of a very large object | | "Do I need compact output?" | Minify | Valid JSON with whitespace removed | Smaller network impact that matters in practice |

The path preview intentionally shows a limited first slice of a structure. For large payloads, search and schema tooling in your development environment remain important.

Pair JSON inspection with a diff

When you correct a fixture or compare two response samples, prettify both versions first and open Diff Viewer.

Before:

{
  "status": "accepted",
  "meta": { "retry": "false" }
}

After:

{
  "status": "accepted",
  "meta": { "retry": false }
}

The diff captures a meaningful type change that can disappear in a casual read.

A disciplined next step

After local inspection, write down what you actually observed:

The sample parses as JSON. Tree paths show $.meta.retry as a string.
Expected schema behavior has not been verified yet.

This is more useful than writing "the payload is fixed" before contract tests have run.

Related developer notes

FAQ

Does Validate check field types?

No. It parses JSON syntax. A string containing false is valid JSON even when an API expects a boolean.

Is the path panel a full JSON explorer?

No. It is a quick preview of the first paths and value types after a successful transform, useful for orientation rather than exhaustive analysis.

When should I compare formatted payloads?

Whenever you are reviewing a revised fixture, response sample, or config snippet. Formatting first keeps whitespace from hiding meaningful changes.

Continue the developer path

Next, apply the checks to one failed request.

The comparison explains each JSON action. The payload guide shows it inside a realistic debugging sequence.

Inspect a payload

See syntax and field types separately.

Format a safe JSON sample, inspect its visible paths, and keep schema verification in your codebase.