Monu Tools

แปลง JSON เป็น TOML

แปลง JSON เป็น TOML และ TOML กลับเป็น JSON ในทั้งสองทิศทาง ทั้งหมดในเบราว์เซอร์ของคุณ

วิธีใช้ JSON / TOML

  1. 01

    เลือกทิศทาง: JSON เป็น TOML หรือ TOML เป็น JSON

  2. 02

    วาง JSON หรือ TOML ของคุณ

  3. 03

    คัดลอกผลลัพธ์ หรือ swap เพื่อแปลงกลับ

A two-way JSON and TOML converter

This is a two-way converter between JSON and TOML. Pick a direction, paste your data, and copy the result. It is built on a well-tested TOML parser that handles nested tables and arrays of tables correctly.

Everything runs locally in your browser, so your data, which for config files can include hostnames or tokens, never leaves your device.

What TOML is for

TOML (Tom's Obvious, Minimal Language) is a configuration format designed to be obvious to read and to map cleanly onto a hash table. It is what Rust's Cargo uses for Cargo.toml and what Python projects use for pyproject.toml, among many others.

JSON and TOML: similar data, different jobs

JSON and TOML describe similar data but suit different jobs. JSON is the lingua franca for APIs and machine exchange. TOML is built for human-written config, with sections, comments and first-class dates that make a settings file pleasant to edit.

TOML also supports native date and time values and typed numbers, so values keep their meaning rather than all becoming strings, which is part of why it is preferred for configuration.

The one thing to watch: null values

Most data round-trips cleanly, but there is one catch. TOML has no null value. JSON nulls cannot be represented, so remove or replace them before converting to TOML, otherwise the conversion cannot express them.

คำถามที่พบบ่อย

TOML คืออะไร?

TOML คือรูปแบบการกำหนดค่าขั้นต่ำที่ออกแบบมาให้อ่านได้ง่าย ใช้โดยเครื่องมือเช่น Cargo และโปรเจกต์ Python หลายอย่างใน pyproject.toml

ทุกอย่างสามารถแปลงได้สะอาดไหม?

ส่วนใหญ่ใช่ TOML ไม่มี null ดังนั้น JSON nulls ไม่สามารถแสดงได้ ลบหรือแทนที่ก่อนแปลง

ข้อมูลของฉันถูกอัปโหลดไปที่ไหนไหม?

ไม่ การแปลงทำงานทั้งหมดในเบราว์เซอร์ของคุณ ดังนั้นข้อมูลของคุณไม่ออกจากอุปกรณ์

แหล่งข้อมูล

ฝังเครื่องมือนี้

เพิ่มเครื่องมือนี้ลงในเว็บไซต์ของคุณเอง คัดลอกสคริปต์ด้านล่าง โดยจะอัปเดตให้เป็นปัจจุบันโดยอัตโนมัติ

<iframe src="https://monu.tools/embed/th/json-toml-converter" width="100%" height="640" style="border:1px solid #e5e5e5;border-radius:12px;max-width:680px" loading="lazy" title="Monu Tools"></iframe>

เครื่องมือที่เกี่ยวข้อง