YAML to CSV Converter
Convert array-shaped YAML into CSV, and CSV back into YAML, bidirectionally, with dot-notation flattening and type inference.
YAML to CSV and CSV to YAML, One Tool
YAML represents data as nested maps and lists, which is flexible but not tabular. CSV (Comma-Separated Values) represents data as flat rows and columns — the format every spreadsheet tool, BI platform, and bulk-import feature understands. Converting YAML → CSV means turning a YAML list of maps at the root into a table: each item becomes a row, and each key becomes a column. Nested maps are flattened into dot-notation column names automatically, so a city key inside an address map becomes an address.city column.
CSV → YAML runs the same idea in reverse: each row becomes one item in a YAML list, with column headers as keys. Type inference is on by default, so values like 42, true, and empty cells become real numbers, booleans, and nulls in the output instead of quoted strings — turn it off to keep every value as plain text.
This page converts entirely in your browser. Paste YAML or CSV — or drag and drop a .yaml/.yml or .csv file — and the conversion runs instantly as you type. Nothing is uploaded to a server.
Why Convert Between YAML and CSV?
Turn a YAML List Into a Spreadsheet
Inventories, user lists, and Ansible variable files are often a YAML list of maps at the root — a natural fit for rows and columns once flattened.
Hand-Edit Config Data in a Spreadsheet
Non-developers can open, filter, and edit a CSV in Excel or Google Sheets far more easily than a YAML file, then convert it back for the app to consume.
Round Out the YAML Converter Set
This sits alongside the YAML ↔ JSON converter, extending the same CSV workflow already available for JSON to YAML-based data lists.
Handling Real-World, Uneven Data
Not every item has every key. Missing keys become blank CSV cells instead of breaking the conversion, so partial or inconsistent records still produce a usable file.
Example
Notice how address becomes two flattened columns, the missing address.zip and tags for Alan Turing are left blank, and the comma and quotes in row three are escaped correctly.
- id: 1
name: Ada Lovelace
address:
city: London
zip: SW1
tags: [math, pioneer]
- id: 2
name: Alan Turing
address:
city: Manchester
- id: 3
name: "Grace \"Amazing\" Hopper"
address:
city: New York, NY
zip: "10001"id,name,address.city,address.zip,tags
1,Ada Lovelace,London,SW1,"[""math"",""pioneer""]"
2,Alan Turing,Manchester,,
3,"Grace ""Amazing"" Hopper","New York, NY",10001,Going the other way, this same CSV converts back into a YAML list of maps with types inferred from each cell:
id,name,city,zip,active
1,Ada Lovelace,"London, UK",SW1,true
2,"Grace ""Amazing"" Hopper",New York,10001,false
3,Alan Turing,Manchester,0161,Features
Bidirectional Conversion
Convert YAML to CSV or CSV to YAML from the same page — just switch direction.
Nested Key Flattening
Nested maps become dot-notation columns automatically — address.city, address.zip — on YAML → CSV.
RFC 4180 Escaping
Values containing commas, quotes, or line breaks are quoted and escaped correctly on the way to CSV.
Type Inference on CSV → YAML
Numbers, booleans, and empty cells become real YAML values instead of quoted strings — turn it off to keep everything as text.
Upload a File
Drag and drop or upload a .yaml/.yml or .csv file depending on the direction.
Copy / Download Output
Copy the result or download it as a standalone .csv or .yaml file.