CSV ↔ YAML Converter
Convert CSV to YAML and YAML to CSV. Choose delimiter, flatten nested fields, auto-type values — all in your browser.
Bidirectional
Convert CSV to YAML or YAML to CSV in one click. Reuse the output as the next input to round-trip and verify.
Flat or nested
Flatten nested YAML into dot.path columns, or keep them as JSON. Mixed-shape rows are unioned automatically.
Private
RFC 4180 CSV parsing and js-yaml emit run locally. Your spreadsheets and configs never leave the browser.
CSV to YAML: rows become mappings
The first row of the CSV is treated as a header by default and becomes the keys of each YAML mapping. Each subsequent row becomes one mapping inside a top-level sequence. Disable the header switch to fall back to generic column names like col1, col2. Auto-typing promotes numbers, true, false, and null to their YAML-native scalar types.
YAML to CSV: choosing the columns
The converter walks every mapping in the input sequence and collects keys in the order it first sees them — the output column order reflects the structure of your data, not an alphabetical re-order. With flattening on, nested mappings become dotted columns (user.name) and lists of objects use bracket indices (items[0].price). Lists of primitives are JSON-encoded into a single cell.
Common use cases
Convert a spreadsheet of users into an Ansible inventory; turn a CSV of feature flags into a Helm values.yaml; export a Kubernetes ConfigMap into a spreadsheet for review; flatten a GitHub Actions matrix YAML into CSV for analysis.
Frequently asked questions
›What does a CSV ↔ YAML converter do?
It converts tabular data between CSV — the format spreadsheets and analysts use — and YAML, the format DevOps tooling and config files use. Each CSV row becomes a YAML mapping inside a top-level sequence; each YAML mapping becomes a CSV row.
›Why convert CSV to YAML?
When you have data in a spreadsheet (users, environments, feature flags, server lists, fixtures) and you need to feed it into a YAML-based tool — Ansible inventory, Helm values, Kubernetes ConfigMaps, GitHub Actions matrices — the converter saves you from hand-typing dozens of mappings.
›Why convert YAML to CSV?
Spreadsheets and BI tools cannot read YAML directly. Converting to CSV lets you open the data in Excel, Google Sheets, Numbers, or pipe it into csvkit, miller, or a database loader.
›What shape of YAML can be converted to CSV?
Either a sequence of mappings (each mapping becomes one row) or a single mapping (treated as one row). Keys across mappings do not have to match — every key becomes a column, with empty cells where a row lacks that key.
›How are nested values handled?
Going YAML → CSV, nested mappings are flattened with dot notation (user.address.city) and lists of objects use bracket indices (items[0].price). Lists of primitives are JSON-encoded into a single cell. Turn off 'Flatten nested' to keep nested values as raw JSON strings.
›What is the 'Auto-typing' option for CSV → YAML?
CSV is stringly-typed — every cell is text. With auto-typing on, values that look like numbers, true/false, or null become YAML scalars of the right type. Turn it off when leading zeros, phone numbers, or other identifiers must stay strings.
›Which delimiters are supported?
Comma (,), semicolon (;), tab, and pipe (|). Semicolon is the default in many European locales where comma is a decimal separator. Tab is common in data-pipeline exports because tabs almost never appear inside fields.
›Is the conversion lossless?
For flat data, yes — round-tripping CSV → YAML → CSV preserves rows and columns. Round-tripping nested YAML through CSV requires flattening, so the column names embed the original structure (user.name) and can be re-nested by hand if needed.
›Is my data sent to a server?
No. Parsing, conversion, and download generation all happen in your browser using js-yaml and a built-in CSV parser. Your data never leaves your device, which is important for spreadsheets with PII or config files with secrets.
More free developer tools
Part of our growing tool belt — all client-side, all free.