About the YAML to JSON
The YAML is parsed with js-yaml using the YAML 1.2 core schema. Anchors (&base) and aliases (*base) are resolved, and merge keys (<<: *base) are expanded, so the JSON shows the data an application actually receives. Comments are discarded because JSON cannot hold them.
Invalid YAML produces an error with the line and column, e.g. a tab used for indentation or a key indented at the wrong level. That makes this a quick validator for docker-compose.yml, Helm values or a CI workflow before you commit.
Type resolution follows YAML 1.2: true/false are booleans, but yes, no and on stay strings. Timestamps such as 2024-01-15 are written as ISO strings. Only the first document of a multi-document stream (separated by ---) is converted. Parsing runs in your browser.
Example: replicas: 3 becomes "replicas": 3 and version: 2.4.1 becomes the string "2.4.1" because it is not a valid number.
How to use it
- Paste YAML or open a .yaml/.yml file.
- Fix any error reported with its line number.
- Choose indentation and copy or download the JSON.