General dev

JSON ↔ YAML Converter

Runs locally

Use JSON ↔ YAML Converter

What it does

Convert JSON into block-style YAML, or read simple key: value YAML back into JSON. The YAML side is a simplified converter, so check the result before you use it in a config.

It runs entirely in your browser: nothing you enter is uploaded.

Example

Blocking rule in JSON

Input
{"rule":"block-phishing-domain","enabled":true,"domains":["login.example.com","verify.example.net"],"action":{"type":"sinkhole","ttl":300}}
Output (captured 2026-10-20)
rule: block-phishing-domain
enabled: true
domains:
  - login.example.com
  - verify.example.net
action:
  type: sinkhole
  ttl: 300

JSON → YAML prints rule and enabled, a domains list with two - items and a nested action map (type: sinkhole, ttl: 300), indented with two spaces.

FAQ

How complete is the conversion?

JSON → YAML handles nested objects and arrays and writes block-style YAML with two-space indentation. YAML → JSON is a simplified line reader: it only understands flat key: value lines and converts true, false, numbers and empty values.

What can go wrong?

Strings are written without quotes, so values such as "1.0", "yes" or text containing ": " or " #" can change type or break the YAML, and empty arrays or objects come out empty. YAML → JSON ignores indentation: nested keys are flattened into one object, list items are dropped or garbled, and quotes and inline comments stay part of the value.

Is my data uploaded?

No. Both directions run in your browser and nothing is sent.