How to convert XML to PDF
- Add the XML files. Drop them on the page or press Select XML files.
- Pick the layout. Page size, landscape for long lines, text size, colours and line numbers.
- Convert. Press Convert to PDF and download it.
Readable code, not a wall of text
Opening an XML file in a browser and printing it gives tiny text, lines cut off at the edge, or one long unbroken line when the file has no line breaks. This tool re-indents the file by depth, keeps short values on their element’s line, wraps long lines, colours the parts and numbers the lines, so a printed or shared copy is easy to read and refer to (“see line 214”).
E-invoices: XRechnung, ZUGFeRD, Factur-X, Peppol
E-invoices are XML files meant for software, which makes them hard to check by eye. When you add one, the PDF starts with a readable page:
- Invoice or credit note number, issue and due dates, currency and IBAN.
- Seller and buyer with their addresses and VAT IDs.
- Every line with quantity, unit price and amount, then the totals and the amount due.
- A check that the line amounts add up to the net total in the file.
Both standards are read: UBL 2.1 (Peppol BIS, XRechnung UBL) and UN/CEFACT CII (XRechnung CII, ZUGFeRD, Factur-X). The original XML is attached inside the PDF, so the legal invoice travels with its readable copy. For long-term archiving, convert the result with PDF to PDF/A.
Also good for
- Config files (.config, .csproj, .plist), sitemaps, RSS and Atom feeds, SVG source, GPX and KML tracks, XLIFF translation files and data exports.
- Code reviews and audits that need a printed, line-numbered copy.
For web pages, use HTML to PDF. Plain text files: TXT to PDF. Combine the PDF with others in Merge PDF.
Safe with any XML
XML can point to other files and web addresses (external entities, style sheets). Nothing like that is followed here: the file is only read as text in your browser, so it can’t fetch anything or run anything, and it is never uploaded.
Frequently asked questions
How is the XML shown in the PDF?
Can I turn an e-invoice (XRechnung, ZUGFeRD, UBL) into a readable PDF?
What if my XML has an error?
Is the text in the PDF selectable?
Can I convert several XML files at once?
Is my XML uploaded? Does it load anything?
Last updated: 2026-11-24