Zero-Custody YAML ↔ JSON Converter & Validator

Convert and validate Kubernetes manifests, Spring Boot configs, and CI/CD pipelines offline. 100% in-browser AST parsing with zero server custody.

Zero-Custody: 100% client-side YAML/JSON parsing. Your configs, secrets, and manifests never leave your browser.
Local AST Engine Active
Presets:
Spec:
Indent:
Multi-Doc:
YAML Input57 lines (1.2 KB)
JSON Output
Valid JSON2 Docs (Multi-Doc)
[
  {
    "apiVersion": "apps/v1",
    "kind": "Deployment",
    "metadata": {
      "name": "order-service",
      "namespace": "production",
      "labels": {
        "app.kubernetes.io/name": "order-service",
        "app.kubernetes.io/part-of": "ecommerce-platform"
      }
    },
    "spec": {
      "replicas": 3,
      "selector": {
        "matchLabels": {
          "app": "order-service"
        }
      },
      "template": {
        "metadata": {
          "labels": {
            "app": "order-service"
          }
        },
        "spec": {
          "containers": [
            {
              "name": "app",
              "image": "ghcr.io/acme/order-service:v2.4.1",
              "ports": [
                {
                  "containerPort": 8080,
                  "name": "http"
                }
              ],
              "env": [
                {
                  "name": "SPRING_PROFILES_ACTIVE",
                  "value": "production"
                }
              ],
              "resources": {
                "requests": {
                  "cpu": "250m",
                  "memory": "512Mi"
                },
                "limits": {
                  "cpu": "1000m",
                  "memory": "1Gi"
                }
              },
              "readinessProbe": {
                "httpGet": {
                  "path": "/actuator/health/readiness",
                  "port": 8080
                },
                "initialDelaySeconds": 15,
                "periodSeconds": 10
              }
            }
          ]
        }
      }
    }
  },
  {
    "apiVersion": "v1",
    "kind": "Service",
    "metadata": {
      "name": "order-service",
      "namespace": "production",
      "labels": {
        "app.kubernetes.io/name": "order-service"
      }
    },
    "spec": {
      "type": "ClusterIP",
      "selector": {
        "app": "order-service"
      },
      "ports": [
        {
          "name": "http",
          "port": 80,
          "targetPort": 8080,
          "protocol": "TCP"
        }
      ]
    }
  }
]

YAML 1.2 Specification & The Infamous "Norway Problem"

In 2009, the YAML standards committee released YAML 1.2 to establish a formal mathematical axiom: every valid JSON file is valid YAML 1.2. Prior to this, YAML 1.1 suffered from aggressive implicit type coercion heuristics that caused widespread production failures across cloud and enterprise environments.

The most notorious of these is the "Norway Problem". In YAML 1.1, the plain scalar NO (the two-letter ISO 3166-1 alpha-2 code for Norway) was defined alongside yes, on, and off as boolean literals. When parsed by older YAML 1.1 libraries (such as legacy PyYAML or older Ruby/SnakeYAML parsers), a country mapping like country: NO was silently mutated into { "country": false }.

YAML 1.2 eliminated these hazards by strictly limiting booleans to literal true and false. This converter runs YAML 1.2 by default, while providing an on-the-fly toggle and automated schema hazard warnings to inspect legacy behavior safely.

Translating Anchors (&), Merge Keys (<<), and Multi-Doc Streams (---)

Multi-Document Streams (---)

Kubernetes Helm charts and manifest bundles place multiple resources (e.g. Deployment, Service, ConfigMap) in a single file separated by ---. Because standard JSON does not support multiple root objects in one payload, this tool seamlessly transforms them into a top-level JSON array or a stream of Newline-Delimited JSON (NDJSON).

Anchors (&) and Aliases (*)

YAML anchors allow developers to adhere to DRY (Don't Repeat Yourself) principles by tagging nodes with &anchor_name and referencing them elsewhere using *anchor_name. During conversion, the engine resolves these references in memory, inserting the concrete dereferenced payload into the JSON AST.

Merge Keys (<<: *anchor)

Commonly used in Docker Compose and CI/CD pipelines (e.g., GitLab CI, Bitbucket Pipelines), the merge key operator <<: *base injects all keys from an anchored mapping into the current map. When 'Resolve Merge Keys' is enabled, the AST engine merges these keys directly into the output object, preserving specific local overrides.

Enterprise Configuration Comparison: YAML vs. JSON

Feature YAML (1.2) JSON (RFC 8259) Architectural Tradeoff
Human Readability Clean indentation, minimal brackets Braces, brackets, and quotes YAML is ideal for human maintenance; JSON is ideal for wire protocols
Comments Support Native (# comments) No comments allowed Configuration requires inline documentation, favoring YAML in DevOps
Multi-Document Native via --- separator Requires outer Array wrapper or NDJSON Kubernetes manifests rely heavily on YAML multi-document streams
DRY Anchors (& / *) Native anchors and merge keys No pointer or reference support YAML prevents duplicate configurations across container fleets
Parser Complexity High (context-sensitive indentation) Very Low (deterministic grammar) JSON parses orders of magnitude faster in web APIs and microservices

Related Zero-Custody Developer Tools

Productivity
JSON to TypeScript Generator →
Convert converted JSON payloads directly into strongly typed TypeScript interfaces.
Security & Cryptography
Base64 & Hex Web Crypto Encoder →
Encode and decode Kubernetes secret values offline with SHA-256 integrity verification.
Security & Tokens
Zero-Custody JWT Auditor →
Inspect and decode JWT tokens offline with alg:none vulnerability audits.
Architecture & Scaling
System Design Capacity Estimator →
Size QPS, peak ingress/egress bandwidth, database storage, and compute nodes.
Identifiers
UUID / ULID Generator →
Generate secure UUID v4, sortable ULIDs, and NanoIDs via native browser Web Crypto CSPRNG.
Date & Time
Unix Epoch Converter →
Convert timestamps across seconds, milliseconds, and nanoseconds with Y2K38 checks.