onlineyamltools logo

Yaml to json converter

World's simplest yaml tool

Quickly convert Yet Another Markup Language to JavaScript Object Notation. Enter YAML in the input box on the left and you'll immediately get JSON in the output box on the right. Enter YAML, get JSON. There are no ads or downloads, and everything works right in your browser. Made by developers for developers.
announcement heads up!
We just launched a new site — Online IMAGE Tools — utilities for working with all image formats. Check it out!
fullscreen fullscreen_exit
JSON Output Indentation
Indent JSON with spaces.
Output indent size. Set to 0 to compress JSON.
Indent JSON with tabs.
Yaml to json converter tool What is a yaml to json converter?
This YAML to JSON converter transforms YAML (Yet Another Markup Language) configs and files into JSON (JavaScript Object Notation) configs and files. It doesn't have any unncessary configuration options. The only thing you can configure is JSON's output. There are three options: indent JSON with spaces, indent JSON with tabs, or compress JSON output.
Yaml to json converter examples Click to use
Convert a YAML list to a JSON list
In this example we convert a YAML sequence of animals to a JSON array and we set output to be indented with two spaces.
- turtle - frog - mangoose - giraffe
[ "turtle", "frog", "mangoose", "giraffe" ]
Required options
These options will be used automatically if you select this example.
Indent JSON with spaces.
Output indent size. Set to 0 to compress JSON.
Convert inline and indented YAML blocks to a JSON object
In this example we convert an inline YAML associative array to a JSON oject and we set output to be minified.
- {waterfall: Angel Falls, height: "3,212 ft"} - waterfall: Tugela Falls height: "3,110 ft"
[{"waterfall":"Angel Falls","height":"3,212 ft"},{"waterfall":"Tugela Falls","height":"3,110 ft"}]
Required options
These options will be used automatically if you select this example.
Indent JSON with spaces.
Output indent size. Set to 0 to compress JSON.
Pro tips Master online yaml tools
You can pass input to this tool via ?input query argument and it will automatically compute output. Here's how to type it in your browser's address bar. Click to try!
https://onlineyamltools.com/convert-yaml-to-json?input=-%20turtle%0A-%20frog%0A-%20mangoose%0A-%20giraffe&indent-use-spaces=true&indent-spaces=2
All yaml tools
Didn't find the tool you were looking for? Let us know what tool we are missing and we'll build it!
Quickly color code the syntax of a YAML file.
Quickly prettify a YAML configuration file.
Quickly minify a YAML configuration file.
Quickly check a YAML file for syntax errors and report them.
Quickly convert a YAML config to a JSON config.
Quickly convert a JSON file to a YAML file.
Quickly convert a YAML document to an XML document.
Quickly convert XML markup to YAML markup.
Quickly convert YAML data to CSV data.
Quickly convert a YAML dataset to a CSV dataset.
Quickly convert YAML format to TSV format.
Quickly convert TSV files to YAML files.
Quickly convert YAML to a PNG, GIF, JPG or BMP Image.
Quickly convert YAML to base-64 encoding.
Quickly convert previously base-64 encoded YAML back to YAML.
Quickly URL-escape a YAML file.
Quickly URL-unescape a YAML file.
Quickly edit a YAML file in a simple YAML editor.
Quickly generate random YAML configs.
Coming soon These yaml tools are on the way
Diff Two YAML Files
Compare two YAML files and show differences between them.
Show YAML Statistics
Show detailed information about a YAML config.
Truncate YAML
Loop over YAML and truncate lists, arrays, and strings.
Create PHP array from YAML
Convert YAML config to a PHP data structure