Config Format Converter

配置格式转换器

在 YAML、JSON、TOML 三种配置格式之间转换。

输入
输出

快速提示

  • JSON → YAML: JSON 键变为 YAML 顶层键,数组变为 YAML 列表
  • YAML → JSON: YAML 映射变为 JSON 对象,列表变为 JSON 数组
  • TOML → JSON: TOML 表格变为对象,点号键创建嵌套,方括号数组

Config Format Converter

All-in-one config format converter for YAML, JSON, TOML

Runs locally · Nothing uploaded

Overview

YAML is used for Kubernetes, GitHub Actions, Docker Compose; TOML for Rust Cargo.toml, Python pyproject.toml, Hugo config.toml; JSON for API responses and config files. This tool performs all format conversions locally in the browser with structured tree view and syntax error hints. Supports YAML, TOML, JSON — easily switch between formats for developers, DevOps, and engineers. No server upload, full privacy protection.

Features

  • YAML ↔ JSON bidirectional conversion
  • TOML ↔ JSON conversion
  • Support for TOML, YAML, JSON formats
  • Structured display with collapsible tree view
  • Real-time syntax error highlighting
  • One-click copy converted code
  • Browser-based, no upload required

How It Works

  1. 1 Open tool and select conversion mode: YAML→JSON, JSON→YAML, TOML→JSON, JSON→TOML
  2. 2 Paste or input raw data in left editor, tool auto-detects format
  3. 3 If syntax errors exist, error hints appear at bottom to guide fixing
  4. 4 Right side shows tree structure and formatted output
  5. 5 Click "Copy Result" to get converted content for direct use

Tips

  • YAML to JSON preserves key order and array order
  • TOML nested tables ([[products]]) convert to nested arrays in JSON
  • Check YAML/TOML syntax before conversion; tool highlights errors
  • Use VS Code preview plugin to quickly view JSON structure after copy
  • Large config files may cause lag; consider splitting for conversion

Related tools

Tags YAMLTOMLJSONConfigConvert

FAQ

Which YAML version is supported?

Supports YAML 1.2 standard, including common features like numbers, dates, nulls, booleans, anchors, etc.

Which TOML features are supported?

Supports TOML 1.0.0 including tables, nested tables, arrays, datetimes, booleans, etc.

JSON output looks wrong?

Check for non-standard YAML/TOML features like custom tags, anchor references — these cannot be fully represented in JSON.

Can I convert multiple files at once?

One file per session. Open multiple tabs or use copy feature to collect results quickly.

Is data uploaded to server?

All operations run locally in browser. No data is uploaded — completely safe and private.