DevTilt

YAML to JSON

Parse YAML configs into JSON for tools that only accept JSON. Output is pretty-printed with 2-space indentation.

Result

Paste YAML, then Convert.

How to convert YAML to JSON

  1. Paste a single YAML document.
  2. Click Convert.
  3. If parsing fails, check indentation (spaces only, consistent width).
  4. Copy or download the pretty-printed JSON.

What is YAML to JSON?

YAML configs are easy to edit but hard to validate programmatically. Paste your YAML here to get strict JSON that parsers, linters, and API clients can consume — especially useful when a CI step or runtime only accepts JSON.

Why use DevTilt's YAML to JSON?

  • Parses standard YAML 1.2 syntax
  • Outputs strict JSON with quoted strings
  • Handles multi-line strings and nested blocks
  • Reports line-specific parse errors

Common use cases

  • Validating a Kubernetes manifest before applying with kubectl
  • Converting a GitHub Actions workflow snippet to JSON for testing
  • Loading YAML config into a JavaScript application at build time
  • Debugging YAML indentation issues by seeing the parsed structure

FAQ

Single-document YAML is supported. Files with multiple --- documents should be split before converting.
Mappings, lists, strings, numbers, booleans, and null. Anchors and aliases may not round-trip to identical JSON.
Yes. Paste a manifest snippet. Very large files should stay under the 5 MB limit.
No. Parsing and formatting run locally.
YAML is indentation-sensitive. Tabs mixed with spaces or misaligned list items break the parser — align nested keys with spaces only and match the source file's indent width.