Turns valid JSON into YAML. Objects, arrays, strings, numbers, booleans, and null are kept. Keys stay in the order they appear.
About this tool
JSON and YAML can describe the same tree. This page takes JSON you already have and writes YAML that a parser of the JSON schema can load. It does not reorder keys.
{"name":"Ada","qty":2} becomes a YAML map with name and qty. qty stays the number 2. An array stays a list. A JSON string stays a string.
The tool does not sort keys, and it is not a Kubernetes linter. Anchors and aliases are omitted. If the text is not valid JSON, nothing is written.
How to use it
1
Paste JSON or drop a file. The sample button inserts a short example. An object, an array, a string, a number, true, false, or null is accepted.
2
The YAML uses the JSON schema only. Anchors, aliases, and custom tags are not written. Lines wrap near 120 characters.
3
Invalid JSON is rejected. A trailing newline is removed from the output. Keys are not sorted.
What it accepts
{"name":"Ada","qty":2} becomes YAML with name and qty, and qty stays the number 2. A string, a bare number, true, false, null, or an array is also accepted. This is not a Kubernetes linter, and keys are not sorted. The writer adds no anchors, aliases, or custom tags (noRefs). Long lines wrap near 120 characters, and the trailing newline is removed from the output.
Where your data stays
JSON you paste and the YAML produced from it remain in this browser tab. The text is not sent to MegaToolkit. Files over 2 MB are left unread. You can copy the YAML or download the converted text from the page. Leave the tab and the result is gone.
Questions
Does this check Kubernetes YAML?
No. It only rewrites valid JSON as YAML. It does not lint Kubernetes manifests, sort keys, or write custom tags.
Are anchors written?
No. Anchors, aliases, and custom tags are not written. The output uses the JSON schema of YAML only.
What JSON values are accepted?
An object, an array, a string, a number, true, false, or null. Invalid JSON is rejected.
Is the JSON uploaded?
No. The conversion runs in this browser. A file larger than 2 MB is not read. Closing the tab drops the YAML.
Ads stay off until you allow them. The choice is saved in this browser.