Excel to XML Converter

Drop a real xlsx or xls file, not a copy of one column. Every sheet loads, the header row becomes element names, dates arrive as ISO 8601 text instead of Excel serial numbers, and the panel under the output tells you which headings had to be renamed to stay legal XML.

Excel to XML conversion bench

  • Reads binary xlsx
  • Every sheet in the book
  • Nothing is uploaded
Cell values
Convert
Spreadsheet

Drop a workbook herexlsx, xlsm, xls, ods, csv and tsv all open. Sheet names, cell types and merged ranges are read from the file itself.

Or paste rows copied from a sheet
XML outputWaiting for a spreadsheet
0Sheets converted
0Row elements
0Columns mapped
0 BOutput size

A worksheet is a grid. XML is a tree.

Every conversion from Excel to XML answers the same question: which part of the grid becomes the parent, and which part becomes the child. A spreadsheet has no answer built in. Rows and columns sit at the same level of importance, and the meaning lives in a header row a human reads. Turning the sheet into XML forces you to name three things the file never held, and the quality of the output comes down to those three names plus how the cell types are handled on the way through.

Sheet1
sku | product name | unit price
KB-88 | Mechanical Keyboard | 189
MS-12 | Wireless Mouse | 30.25
XML out
<data><row><sku>KB-88</sku><product_name>Mechanical Keyboard</product_name><unit_price>189</unit_price></row></data>

The three names you pick

Two of them sit in the controls above. The third comes out of your header row, one element name per column.

NameWhere it landsWhat to write there
RootThe single outer element wrapping the whole documentWhat the file is a list of, in plural form: products, invoices, employees. XML allows exactly one root, so this element appears once.
RowOne element per data rowThe singular of the root: product, invoice, employee. Anything reading the file will loop over these.
ColumnOne element or attribute per cellRead from your header row, then rewritten where the heading breaks XML naming rules.

The defaults of data and row load the file and tell a reader nothing. If the XML is going into a system with a schema waiting for it, match the names in the schema before you convert. Renaming an element across ten thousand rows afterwards is a find and replace nobody enjoys running twice.

Column headings XML will not accept

An XML element name has rules a spreadsheet heading never had to follow. It starts with a letter or an underscore, holds no spaces, and reserves anything beginning with the letters xml. Real headers break all three constantly, so each one is rewritten and the note panel lists what changed.

Heading in the sheetElement name writtenReason
product nameproduct_nameSpaces end a name in XML, so the parser would read a second attribute
Q1 %Q1__Percent, slash, comma, brackets and currency symbols are all outside the allowed set
2026 totaln_2026_totalNo XML name starts with a digit, so a prefix goes on the front
xmlVersionx_xmlVersionNames starting with xml in any casing are reserved by the specification
Blank cell in the header rowcolumn4An unnamed column still needs a tag, numbered by position
Two columns both called totaltotal, total_2Sibling elements repeat legally, but a repeated name under one row is ambiguous to read back

Rewritten names break the round trip. If the XML is going back into a spreadsheet later, product_name comes home as a column called product_name, not product name. Rename the headers in Excel before converting when the exact wording matters, since a heading you control is easier to fix than a mapping file you have to maintain.

What each kind of cell turns into

XML holds text and nothing else. Every cell type in the workbook has to be flattened into a string, and a few of those flattenings lose information worth knowing about.

Cell in ExcelText in the XMLWhat to watch
TextThe string as storedAmpersands and angle brackets are escaped to &amp; and &lt;. Control characters XML 1.0 forbids are stripped.
NumberThe stored value, not the displayed oneA cell showing $1,200.00 writes as 1200. Display formatting lives in the sheet, not the data.
Date or time2026-01-14 or 2026-01-14T09:30:00Excel stores dates as serial numbers counted from 1900. The ISO option converts them. Turn it off and you get full timestamps instead.
Booleantrue or falseLowercase, matching what XML Schema and most parsers expect from a boolean.
FormulaThe last calculated resultThe formula text is dropped. A workbook saved before recalculation carries stale values into the XML.
Blank<price/> or an empty attributeAn empty element and a missing element mean different things downstream. Every column is written for every row, so a gap in the sheet becomes an empty tag rather than an absent one.
Error such as #N/AThe error textClean these out in Excel first. An #REF! string sitting in a price field passes schema validation on type string and fails everything after.

Child elements or attributes

Both are valid XML for the same data, and the choice is the one people argue over longest. Element mode nests each cell in its own tag. Attribute mode puts every value on the row tag and closes it in one line.

Child elements
<row><sku>KB-88</sku><unit_price>189</unit_price></row>
Attributes
<row sku="KB-88"
unit_price="189"/>

Attribute output runs roughly forty percent smaller on a wide sheet, which matters when the file crosses a network. It also closes doors. An attribute appears once per element, holds no child structure, and normalises whitespace, so a multi line address or a value with tabs in it comes back changed. Pick attributes for compact identifiers and flags. Pick elements for anything a person typed, anything that might grow children later, and anything a schema already describes as an element.

Workbooks with more than one sheet

Loading a file shows a tab per worksheet, and the active sheet converts on its own by default. Switch to whole workbook and each sheet becomes a named wrapper element under the root, keeping the sheet name as structure rather than losing it.

<data><Orders><row>...</row></Orders><Customers><row>...</row></Customers></data>

Worth knowing before you reach for it: each sheet gets its own header row and its own set of column names, so a workbook where the sheets hold unrelated shapes produces XML with unrelated shapes inside one document. That is fine for an archive and awkward for a schema. When the sheets are monthly slices of the same table, convert them one at a time and concatenate the row elements instead.

Five things to check before the file goes anywhere

  1. Merged cells. A merge stores the value in the top left cell and leaves the rest of the range empty. A title merged across five columns writes one populated element and four empty ones. Unmerge and fill down in Excel first, and the note panel flags the ranges it found.
  2. Leading zeros. A SKU of 00457 stored as a number arrives as 457. Excel dropped the zeros long before the conversion started. Format the column as text in the sheet, then reload the file.
  3. Long numbers. Anything past fifteen digits, which covers most credit card numbers and some barcodes, loses precision inside Excel itself. Check a sample against the source system rather than against the sheet.
  4. Trailing blank rows. A sheet where someone deleted content without deleting rows reports a used range far past the data. Dropping blank rows is on by default for exactly this reason, and the note panel counts what went.
  5. Hidden rows and filters. Hidden rows are still rows. Everything in the used range converts, filtered out or not. Delete what you do not want rather than hiding it.

Working through a real export

  1. Save the workbook from Excel with formulas recalculated, so the cached values in the file match what the sheet displays.
  2. Drop the file above and pick the sheet holding the table. The preview shows the first eleven rows so you catch a title row sitting above the headers.
  3. Set the root and row names to whatever the receiving system expects. If a schema exists, take the names from the schema.
  4. Read the note panel. Renamed headings and merged ranges are the two entries worth acting on before you go further.
  5. Download the file and validate it against the target schema. Structure is correct by construction here. Whether the values satisfy the schema is a separate question this tool has no way to answer.

What this converter leaves to you

Nothing you load is uploaded. The workbook is parsed in this page and the XML is built in this page, so a sheet holding payroll or customer records never leaves your machine. Load the page once, drop your network connection, and the converter keeps working. Going the other direction is covered by the XML to Excel converter, and a plain comma separated file with no workbook around it is a better fit for CSV to XML.

Questions about converting Excel to XML

File formats, element naming, date handling, multi sheet workbooks and the limits worth knowing.

Does this open a real xlsx file, or do I have to paste CSV?

It opens the file. Drop an xlsx, xlsm, xls, ods, csv or tsv and the workbook is parsed in the browser, sheet names and cell types included. Pasting rows still works for a quick check, and pasted text is treated as one sheet named Sheet1. The advantage of loading the file is that cell types survive: a date stays a date instead of arriving as whatever text Excel put on the clipboard.

Why did my column heading change in the output?

XML element names follow rules a spreadsheet heading does not. Spaces become underscores, symbols such as percent and slash become underscores, a heading starting with a digit gets an n_ prefix, and a heading starting with the letters xml gets an x_ prefix because the specification reserves that. Repeated headings get a numeric suffix. Every rewrite is listed in the note panel under the output, so you see exactly which columns moved.

How are Excel dates handled?

Excel stores a date as a number counting days from 1900, which is meaningless in an XML file on its own. With the ISO 8601 option on, a date cell writes as 2026-01-14 and a cell carrying a time component writes as 2026-01-14T09:30:00. Turn the option off and you get a full timestamp string instead. The distinction matters if the receiving schema declares the field as xs:date, since a serial number will fail validation there.

Should cell values go into child elements or attributes?

Use elements unless you have a reason not to. Elements accept any content, keep whitespace as typed, and leave room to add children later. Attributes produce a smaller file and read well for short identifiers and flags, at the cost of normalising whitespace and ruling out any future nesting. When a schema already exists, follow whatever the schema declares rather than picking on file size.

My workbook has several sheets. What happens to them?

A tab appears for each worksheet and the active one converts by default. Switch the scope control to whole workbook and every sheet is written as its own named wrapper element under the root, so the sheet names survive as structure. Sheets holding different column shapes end up as different shapes inside one document, which is fine for an archive and awkward for anything validating against a schema.

Why are some elements empty in my output?

Three causes account for nearly all of them. The cell was blank in the sheet. The cell sits inside a merged range, where only the top left cell holds the value. Or the row is entirely blank and the drop blank rows option is switched off. Every column is written for every row, so a gap becomes a self closing element rather than a missing one, which is a distinction that matters if the consumer treats an absent element differently from an empty one.

Are formulas converted or evaluated?

Neither. The value Excel cached the last time it calculated is read from the file and the formula text is discarded. If the workbook was saved with calculation set to manual and the sheet was edited afterwards, those cached values are stale and the XML inherits the stale numbers. Open the workbook, force a recalculation, save, then convert.

How large a spreadsheet will this handle?

Parsing and XML generation both run on the main thread in your browser, so it depends on your machine rather than a server limit. Sheets in the tens of thousands of rows convert in a second or two. Past a few hundred thousand rows the tab will stall long enough to be unpleasant, and a script using the same parsing library is the better answer at that size.

Is the file uploaded anywhere?

No. The workbook is read by JavaScript running in this page and the XML is built there too. No request carries your data after the page loads, nothing is stored between visits, and closing the tab clears everything. A spreadsheet holding salaries, customer records or unreleased figures stays on your machine.