Chuyển INI sang JSON

Cần chuyển đổi ngược không?
JSON to INI Converter

Đầu vào: INI

1

Đầu ra: JSON

Nhập dữ liệu INI để chuyển đổi sang JSON

Dữ liệu đã chuyển đổi sẽ hiển thị ở đây

Cách chuyển INI sang JSON

  1. Bước 1 – Dán nội dung INI

    • Dán cấu hình INI chuẩn (key toàn cục và [sections]).
    • Comment bắt đầu bằng ; hoặc # sẽ bị bỏ qua trong JSON.
    • Bạn có thể import file .ini hoặc .txt từ máy tính.
  2. Bước 2 – Kiểm tra chuyển đổi

    • Key toàn cục vẫn nằm ở root của object JSON.
    • Section như [database] trở thành object lồng nhau trong JSON.
    • Giá trị số được tự động nhận diện và ép kiểu khi có thể.
  3. Bước 3 – Lấy JSON

    • Dùng JSON để chuyển cấu hình cũ sang ứng dụng hiện đại.
    • Sao chép vào clipboard hoặc tải xuống file .json.
Example: INI to JSON
# Input INI
driver = postgres

[connection]
host = localhost
port = 5432

// Output JSON
{
  "driver": "postgres",
  "connection": {
    "host": "localhost",
    "port": 5432
  }
}

Related tools

Câu hỏi thường gặp

What is INI format?

INI files are configuration files that store data in sections with key-value pairs. They're commonly used in Windows applications and system configurations.

How are INI sections converted to JSON?

INI sections become JSON objects. Global key-value pairs (outside sections) are placed at the root level, while sectioned data creates nested objects.

What data types are supported?

The converter automatically detects numbers, booleans (true/false), and null values. Arrays can be represented as comma-separated values in INI.

Can I convert nested JSON back to INI?

Yes. Use the JSON to INI converter. Nested objects become INI sections, and arrays are converted to comma-separated values.

Is my data secure?

Yes, all data processing happens entirely in your browser. Your data is never sent to any server, ensuring complete privacy and security.

Chuyển INI sang JSON | JSONSwiss