Converter Tools
YAML to JSON Converter
Convert YAML to JSON and JSON to YAML in your browser. Block, flow, anchors, aliases, multi-line scalars, with line and column error reporting.
Convert
YAML and JSON in either direction
Output indent
YAML input supports block mappings, sequences, flow [..] and {..}, literal | and folded > block scalars, anchors and aliases.
Conversions run entirely in your browser. Nothing you paste is sent to a server.
How to use
- Pick a direction: YAML to JSON or JSON to YAML.
- Paste your YAML or JSON into the input area, or click Load sample to see an example with anchors, block scalars, and flow collections.
- Pick an output indent (2 spaces, 4 spaces, or minified for JSON output).
- Read the document, key, and byte stats above the output and click Copy to copy the result. Use Swap direction to feed the output back in.
About this tool
YAML to JSON Converter parses YAML 1.2 in your browser and gives you the equivalent JSON, ready to paste into a config file, an HTTP request body, a CI pipeline, or a tool that only speaks JSON. Paste a YAML document and the converter handles block-style mappings (key: value) and sequences (- item), nested structures with significant indentation, flow-style mappings ({a: 1, b: 2}) and sequences ([1, 2, 3]) that span multiple lines, plain scalars typed by the YAML 1.2 core schema (null, true/false, integers, floats, strings), single-quoted and double-quoted strings with full escape sequences (\n, \t, \xNN, \uNNNN, \UNNNNNNNN), block scalars in literal (|) and folded (>) styles with strip and keep chomping indicators (|-, |+, >-, >+), comments, document separators (---), anchors (&name), and aliases (*name) that share structure. Errors include the exact line and column number so you can find malformed input quickly. The reverse direction takes any valid JSON and emits clean YAML with sensible quoting: keys that need quoting (reserved words like null, yes, on, off, strings that look like numbers) are quoted automatically, multi-line strings are emitted as escaped double-quoted scalars to preserve content, and indentation matches the size you pick (2 or 4 spaces). Useful for Kubernetes manifests, GitHub Actions workflows, GitLab CI pipelines, Docker Compose files, Ansible playbooks, OpenAPI and AsyncAPI specs, Helm charts, CircleCI config, Cloud Build, Serverless Framework, and any place a developer needs to switch between YAML and JSON without copy-paste-edit. Conversions run entirely in your browser, so the configs and secrets you paste never leave your device.
Free to use. Works in your browser. No signup, no login.
Related tools
You may also like
JSON Formatter
Format, minify, and validate JSON in your browser.
Open tool
ConverterCSV to JSON Converter
Two-way CSV and JSON converter with delimiter and header controls.
Open tool
ConverterMarkdown to HTML Converter
Convert Markdown to clean HTML with a live preview and copy button.
Open tool
DeveloperRegex Tester
Live regex testing with highlights, capture groups, and replacement preview.
Open tool