How to convert a PDF to XML
- Upload the PDF in the box above. The limit is 8MB per file.
- Click Extract Tables. The converter looks for tables on every page.
- Click Export to XML. The XML file downloads to your computer.
Ordinary tables convert at no cost and with no account. Uploaded files are deleted automatically after 24 hours.
What the XML file looks like
<?xml version="1.0" encoding="UTF-8"?>
<tables>
<table number="1">
<row>
<cell column="Item">Paper</cell>
<cell column="Qty">2</cell>
<cell column="Price">1,250.00</cell>
</row>
</table>
</tables>- Encoding is UTF-8.
- All tables from the PDF go into one file, in the order they appear.
- Each cell keeps its column name in the column attribute.
- If a table has no header row, the names are Column 1, Column 2 and so on.
- Characters like & and < are escaped, so the file stays valid XML.
Opening the file
- Excel: Data > Get Data > From File > From XML. If you only need a spreadsheet, click Export to Excel instead.
- Code: any XML parser works, for example
xml.etree.ElementTreein Python.
Other formats
The same extraction also gives you Excel and CSV. See also PDF to JSON and PDF to CSV.
Questions and answers
How do I convert a PDF to XML?+
Upload the PDF on this page, click Extract Tables and then Export to XML. The converter finds the tables in the PDF and writes their rows and cells to an XML file.
Does it convert the whole PDF to XML?+
No. It exports table data only. Headings, paragraphs and images are left out, and the page layout is not kept. If the PDF has no tables, there is nothing to export.
Can I use my own XML schema?+
Not on this page. The file has one fixed structure: tables, table, row and cell. To match another schema, transform the file afterwards, for example with XSLT or a short script.
Why are column names in an attribute?+
Column names in a PDF often have spaces or symbols, which are not allowed in XML tag names. As an attribute they stay exactly as printed.
Can I convert a scanned PDF to XML?+
Yes. When the PDF is a scan, the converter runs text recognition (OCR) first. For hard scans, deep extraction reads the page like a person does; you see one page of the result before you pay.
How long do you keep my PDF?+
Uploaded files and results are deleted automatically after 24 hours.