PDF to XRechnung Converter API
XRechnung XML for German B2G portals, validated against EN 16931 and the KoSIT rules. Try the REST API demo, no code required. Drop a PDF to see exactly what InvoiceXML returns.
Required for XRechnung. The Leitweg-ID is the routing identifier for your German government recipient.
Drop a PDF to test the API
or browse files to upload
REST API demo · POST /transform/to/xrechnung · PDF · Max 20 MB
Review every result before you use it. AI can make mistakes. Before you send the invoice or submit it to an authority, check every value in the XML against your PDF.
From Messy Scanned PDF to Compliant XML
See exactly how your invoices are transformed automatically.
PDF Invoice
Unstructured
Legacy / scanned PDF with no embedded data
AI Extraction
Processing
OCR & AI extraction with confidence scores
Data Mapping
Structuring
Data mapped to selected compliance schema
Compliant Output
Validated ✓
All validation checks passed (XSD + Schematron)
Why XRechnung for German E-Invoicing?
XRechnung is the mandatory format for invoicing German public authorities. Unlike hybrid PDF formats, XRechnung delivers a pure, machine-readable XML that government portals process automatically, no manual data entry, no delays. With Germany's e-invoicing mandate expanding to B2B from 2025, adopting XRechnung now future-proofs your invoicing workflow and ensures compliance with both national and European regulations.
Built for Developers
A single REST endpoint. Send a PDF, receive structured XML. Built for ultra-high concurrency and sub-second processing.
- Native, scanned and photographed PDF invoices, no preprocessing needed
- Every response validated against official Schematron rules
Supports ZUGFeRD · Factur-X · XRechnung · UBL · CII · EN 16931
API Documentation$ curl -X POST https://api.invoicexml.com/v1/transform/to/xrechnung \ -H "Authorization: Bearer sk_live_..." \ -H "Content-Type: multipart/form-data"\ -F "[email protected]" // => 200 OK // => { "id": "inv_8f3k...", "status": "completed" }
Complete XRechnung Toolkit
Everything you need to create, convert, validate, and preview XRechnung invoices, via REST API or online.
AI output requires human review of the structured data before use
With XRechnung, the XML is the invoice. It is what the recipient's software and the tax authority process, so every value in it must be checked before you send it.
Check the values inside the XML
The XML is what the AI produced from your PDF. Compare these values in it against your source PDF:
- Seller and buyer names, addresses and tax identifiers
- Invoice number, issue date, due date and payment terms
- Line items, quantities, unit prices and line totals
- Tax rates, tax amounts and invoice totals
- Payment details, such as the IBAN
See the XML in a readable form
- Upload it to our online XRechnung preview.
- Or use our API: render it as a PDF with POST /v1/render/xml/to/pdf.
The rendered PDF is built only from the XML values, so what you read there is exactly what the recipient's system receives. Only send, book or submit the invoice once every value matches. Our Terms of Service require this review for all AI output.
Frequently Asked Questions
What is XRechnung?
XRechnung is the German standard for electronic invoicing with public authorities. It implements the European Norm EN 16931 as a CIUS (Core Invoice Usage Specification) and adds stricter rules required by German federal, state, and municipal government recipients.
Is XRechnung mandatory in Germany?
Yes. Since November 2020, all invoices sent to German federal authorities must be in XRechnung format. Most state and municipal authorities have followed with similar mandates. From 2025, all German businesses must be able to receive structured e-invoices.
What is a Leitweg-ID?
A Leitweg-ID is a routing identifier used by German government recipients to direct incoming invoices. It is mandatory for XRechnung invoices sent to public authorities. Enter it in the Buyer Reference field: it is required, and it replaces anything read from the PDF.
How does XRechnung differ from ZUGFeRD?
XRechnung produces a standalone XML file designed for automated processing on B2G portals like ZRE and OZG-RE. ZUGFeRD produces a hybrid PDF with embedded XML, intended primarily for B2B exchange. Both conform to EN 16931 but serve different submission channels.
Ready to automate your invoices?
Validate, convert and embed compliant e-invoices through one API. Start your 30-day free trial. No credit card required.