YAML and JSON converter
Convert a limited YAML 1.2 subset and JSON locally, preserving exact numeric lexemes and rejecting unsupported structures instead of silently losing data.
How to use
Choose conversion direction and input source. Paste text or select a local UTF-8 file, then convert and review the preview and style-loss notice. Explicitly copy the complete result or download converted.json or converted.yaml. Oversized text or a file that could not be read stays rejected until that same input is corrected; editing another option does not process an old value. Reading and conversion can be cancelled; the original file stays unchanged.
YAML n: 9007199254740993 produces JSON retaining that exact number. JSON {"n":1e400,"name":"Arabic"} produces YAML retaining 1e400 without Infinity. .5 becomes 0.5 and 0o10 becomes 8, while yes and the date 2026-09-25 remain strings.
Support & limits
Values, map/sequence order and JSON-grammar number lexemes are retained without Number conversion; supported YAML numeric forms are normalized textually and unsigned hex/octal uses BigInt. No YAML 1.1 or preservation of comments/styles/quotes/source line endings; output is UTF-8 without BOM and with final LF. Aliases, anchors, explicit tags including !!str, directives, multiple documents, merges, non-string/duplicate keys, NaN/Infinity and shorthand flow pairs such as [a: b] are rejected. Use explicit maps. Files require valid UTF-8; input BOM is retained and accepted initially by YAML but rejected by JSON. Preview is text only and may end inside a combined character; clipboard line endings may vary by system. Nothing is uploaded, saved, executed or followed as a link.
Common questions
Does the converter support all YAML or automatically repair documents?
No. It converts the declared YAML 1.2 subset representable by JSON values and rejects unsupported or over-budget input. Conversion is not sanitization or schema validation, and does not guarantee that another application reads large numbers without rounding. Bounded processing does not guarantee a total browser-memory ceiling.
Related tools
JSON formatter and validator
Format, minify and validate JSON while preserving large numbers and rejecting duplicate keys.
CSV and JSON converter
Convert CSV tables and JSON locally while preserving string cells and checking headers and quotes.
Structural JSON diff
Compare two JSON structures and inspect additions, removals and changes at explicit paths, preserving number spellings without rounding.