No file open
Create a new file or open an existing one from the sidebar
Paste your YAML and press To JSON in the Convert panel.
No file open
Create a new file or open an existing one from the sidebar
To convert YAML to JSON, paste the YAML above, open Convert and press To JSON in the YAML section. You get formatted JSON with two space indentation, and if the YAML has a syntax error you'll see the error instead of a half converted file.
Anchors and aliases are expanded into full copies, and comments are dropped since JSON has nowhere to keep them. Keys like on stay as strings, which matters for GitHub Actions workflows like the one in the example.
name: CI
on:
push:
branches: [main]
pull_request:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- run: npm ci
- run: npm test{
"name": "CI",
"on": {
"push": {
"branches": [
"main"
]
},
"pull_request": null
},
"jobs": {
"test": {
"runs-on": "ubuntu-latest",
"steps": [
{
"uses": "actions/checkout@v4"
},
{
"uses": "actions/setup-node@v4",
"with": {
"node-version": 22
}
},
{
"run": "npm ci"
},
{
"run": "npm test"
}
]
}
}
}Usually it's indentation. YAML uses spaces for structure, tabs aren't allowed for indenting, and one misaligned line changes the meaning. Press Validate with the YAML tab open to see the parser's message, which points at the line and column.
One document at a time. If the file has several documents separated by ---, convert them one by one.
Dates come through as strings, exactly as they were written, so nothing gets shifted by time zones.
No, this runs entirely in your browser, so nothing you paste is sent to a server. The only feature that sends data anywhere is the optional AI assistant, and only when you actually ask it something.