About XML to TSV
TSV is a common export format for spreadsheets and databases. This tool parses XML, treats repeated child elements of the root as rows, and their child elements as columns. Runs entirely in your browser.
TSV is a common export format for spreadsheets and databases. This tool parses XML, treats repeated child elements of the root as rows, and their child elements as columns. Runs entirely in your browser.
Flatten an XML document into tab-separated values, the format big-data tools and spreadsheets are happiest with. The converter parses the input with the browser’s DOMParser, finds the repeating element that should become rows, and emits one TSV line per record. The first line is the header row of column names taken from child element names.
Embedded tab and newline characters inside values are escaped to \t and \n so each record stays on exactly one line and every column boundary is a real tab. Attributes can be included as @-prefixed columns. Pick LF or CRLF line endings depending on whether the consumer is a Unix tool or Excel on Windows.
TSV is simpler — no quoting rules — because tabs almost never appear in plain text. It’s the default ingestion format for many big-data tools (Hadoop, Hive, BigQuery LOAD), and pasting it into a spreadsheet auto-splits to columns without a dialog.
It is escaped to \\t or \\n in the output (a literal backslash plus the letter t or n). This keeps every record exactly one line and every field separated by a real tab. Reverse the escape on the consumer side if needed.
They become extra columns prefixed with @ in the header (e.g. <item id="3"> contributes a column @id with value 3). Switch the attribute option off if you only want element values.
No — parsing and serialisation both run in your browser via DOMParser.
Explore the full suite of DATA FORMATS tools and 290+ other free utilities at Chunky Munster.