Convert Kubernetes Manifests Between YAML and JSON
Every k8s manifest is YAML by convention and JSON by capability. Tooling — Terraform, admission webhooks, client libraries — often wants the JSON form.
Multi-document files
A file with --- separators converts to a JSON array, one element per resource. Feed elements individually to APIs, or keep the array for batch tooling.
Round-tripping safely
Anchors resolve on the way to JSON, which is what the API server does anyway — the JSON you get here is semantically what the cluster receives. Comments are lost; keep the YAML as source of truth.
kubectl with JSON
kubectl apply -f manifest.json works identically to YAML. JSON shines in generated pipelines where templating YAML's indentation is fragile.
Convert your YAML file now
Free — upload a PDF or image and download a clean spreadsheet.
Open the converter →