How to convert config files
Pick the converter that matches the file you have. Paste or upload TOML or YAML, choose the output options shown on that page, then inspect the JSON or parser message. The TOML page controls JSON layout, while the YAML page controls how multiple documents are handled.
Choose a config file converter
- TOML to JSON Converter turns pasted or uploaded TOML into nested JSON, with pretty or compact formatting, copy and download controls, and parse errors that include a line and column.
- YAML to JSON Converter turns pasted or uploaded YAML into JSON, lets you choose how multiple documents are handled, and reports parser errors with line and column details.
Convert TOML to JSON
Use TOML to JSON Converter for a TOML source. An input containing [server] and port = 8080 becomes nested JSON with a server object and a port value. Choose pretty or compact JSON, then copy or download the result.
Convert YAML to JSON with multiple documents
Use YAML to JSON Converter for a YAML source. Its multiple-document option determines how the page handles input containing more than one document. Input containing name: api and port: 8080 becomes JSON with name and port fields. If the source cannot be parsed, the page reports the line and column of the problem.
Jobs that fit these converters
- A TOML file needs nested JSON. Open TOML to JSON Converter, inspect the pretty output, then copy or download it.
- A YAML file needs to become JSON. Open YAML to JSON Converter and check the parser location if the source is invalid.
- A YAML file contains several documents. Select the multiple-document handling that fits the file, then check the resulting JSON.
When to use Config File Tools instead
Use Config File Tools when you need to validate, compare, merge, or extract environment variables from configuration data. Use this convert section when the result must be JSON from TOML or YAML. The TOML and YAML pages have different options because their source formats differ.
Frequently asked questions
How do I convert a config file to JSON?
Choose the converter for your input format, then paste or upload the TOML or YAML file. Review the JSON and any parser message before using the result.
How do I convert TOML to JSON?
Open TOML to JSON Converter and provide the TOML source. The page produces nested JSON, with pretty or compact formatting, and includes copy and download controls.
How do I convert YAML to JSON?
Open YAML to JSON Converter and provide the YAML source. Choose how multiple documents are handled, then review the JSON and any parser error with its line and column.
Can I convert YAML with more than one document?
Yes. YAML to JSON Converter includes a choice for handling multiple documents. Select the matching behavior, then check the converted output.