Skip to content
MyDailyTool

YAML to CSV Converter

Convert YAML arrays of records to CSV. Flattens nested objects with dot-notation column names so spreadsheet tools can read structured YAML data.

How to use the yaml to csv converter

Paste a YAML array of records on the left. CSV appears live on the right, with each record becoming a row. Works best when your YAML is a flat array of objects with the same keys.

Formula & explanation

YAML → JS array → CSV, using the union of all keys as headers. Nested objects/arrays are JSON-stringified into a single cell.

Examples

- name: Alice\n age: 30\n- name: Bob\n age: 25 becomes name,age\nAlice,30\nBob,25

Frequently asked questions

My YAML has deep nesting — can I still convert?
Yes, but nested structures get JSON-stringified into one cell. CSV is tabular by nature; if your data is a tree, consider using YAML→JSON instead and processing in code.
What if the array isn't at the root?
Currently we assume the YAML root is a sequence (-prefixed list). If your records live under a key, copy just that sub-array as the input.

Related developer tools tools