XML to CSV Converter
Convert repeated XML elements into CSV rows, with each attribute and child element as a column and nested elements named with dots.
How to convert XML to CSV
Paste your XML
Paste or type it into the box, or press Try an example.
Choose the delimiter
Comma, semicolon, tab or pipe.
Copy or download
Open it in a spreadsheet.
Worked example
This is what XML to CSV Converter gives for its own sample values. Open the tool above and change anything to try your own.
XML
<people> <person id="1"><name>Ann</name><city>Paris</city></person> <person id="2"><name>Bob</name><city>Rome</city></person> </people>
- Delimiter
- Comma ( , )
CSV
@id,name,city 1,Ann,Paris 2,Bob,Rome
About XML to CSV Converter
Turn repeated XML elements into spreadsheet rows. Every attribute and child element becomes a column, nested elements are named with dots, and missing values are left blank. The first level of repeated elements becomes the rows.
FAQs
Which elements become rows?
The children of the root element. If there is one wrapper element that holds the repeats, the repeats are used.
What happens to attributes?
They become columns that start with @, such as @id.
Can I check the XML first?
Use XML Validator.