YAML to JSON Converter
Converts YAML to JSON, and points out the type surprises that conversion exposes.
Loading the tool…
How to use this tool
- Paste the configuration you want as JSON.
- Select Convert to JSON.
- Read the types in the output: anything that should be a string and came out as a number or a boolean needs quoting in the original.
What yaml to json does
YAML is a superset of JSON, so this direction always works in principle. What it exposes is how much guessing YAML does about types. An unquoted value is a number if it looks like one, a boolean if it is any of true, yes, on or their variants, and null if it is a tilde or empty. Once it is JSON those guesses are locked in and visible.
That is exactly why the conversion is worth doing before you debug a configuration problem. A version pinned as 1.10 becomes the number 1.1, a country code of NO becomes false, and a build number of 0800 becomes 800. Each of those has caused a real outage somewhere. Converting to JSON shows you the values as your loader will actually see them.