• 00Days
  • 00Hours
  • 00Mins
  • 00Sec
40% Off

Use coupon code

Limited Offer!

What Is XRechnung? Format, XML Example & 2027 Requirements

What Is XRechnung? Format, XML Example & 2027 Requirements

AI Summary

Germany’s transition to mandatory electronic invoicing is changing how businesses create, exchange, and process invoices. With the next major e-invoicing deadline approaching in January 2027, businesses need to understand one of Germany’s most widely recognized electronic invoice standards: XRechnung.

XRechnung is a German electronic invoicing standard based on the European standard EN 16931. It uses structured XML data to enable the automated exchange and processing of invoices between businesses and public authorities.

The term XRechnung (pronounced approximately iks-rekh-noong) combines Rechnung, the German word for invoice, with the X prefix used for German government data standards such as XBau and XMeld, all of which are XML-based.

In this guide, we’ll explain how XRechnung works, what an XRechnung file looks like, how to validate one, and what Germany’s upcoming e-invoicing requirements mean for your business.

What Is XRechnung?

XRechnung is Germany’s national implementation of the European electronic invoicing standard EN 16931. It was developed for electronic invoicing in public procurement and is maintained by the Coordination Office for IT Standards (KoSIT).

Although originally introduced primarily for business-to-government (B2G) transactions, XRechnung is also suitable for business-to-business (B2B) invoicing.

A traditional PDF invoice presents information in a format designed for people to read. XRechnung organizes the same information into standardized data fields that accounting systems, ERP software, and invoice processing applications can interpret automatically.

This eliminates the need to manually enter invoice information or extract it from PDF documents using optical character recognition (OCR).

How Does the XRechnung Format Work?

XRechnung supports two XML syntaxes:

  • UBL (Universal Business Language): An internationally recognized XML syntax for exchanging business documents, including invoices.
  • CII (Cross Industry Invoice): An XML invoice syntax developed by UN/CEFACT for exchanging invoice information across industries.

Both syntaxes represent the same underlying invoice data model but organize information using different XML structures.

XRechnung also introduces Germany-specific business rules on top of EN 16931 to accommodate national invoicing requirements.

XRechnung Format Example: What Does an XRechnung File Look Like?

An XRechnung invoice is typically delivered as an .xml file. When opened in a text editor, it displays structured tags rather than a conventional invoice layout.

Here’s a simplified XRechnung example using UBL syntax, with fictional invoice details.

<ubl:Invoice

xmlns:ubl=”urn:oasis:names:specification:ubl:schema:xsd:Invoice-2″

xmlns:cbc=”urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2″

xmlns:cac=”urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2″>

<cbc:CustomizationID>urn:cen.eu:en16931:2017#compliant#urn:xeinkauf.de:kosit:xrechnung_3.0</cbc:CustomizationID>

<cbc:ID>INV-2027-001</cbc:ID>

<cbc:IssueDate>2027-01-15</cbc:IssueDate>

<cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>

<cbc:DocumentCurrencyCode>EUR</cbc:DocumentCurrencyCode>

<cbc:BuyerReference>BUYER-001</cbc:BuyerReference>

<cac:TaxTotal>

<cbc:TaxAmount currencyID=”EUR”>190.00</cbc:TaxAmount>

</cac:TaxTotal>

<cac:LegalMonetaryTotal>

<cbc:TaxExclusiveAmount currencyID=”EUR”>1000.00</cbc:TaxExclusiveAmount>

<cbc:TaxInclusiveAmount currencyID=”EUR”>1190.00</cbc:TaxInclusiveAmount>

<cbc:PayableAmount currencyID=”EUR”>1190.00</cbc:PayableAmount>

</cac:LegalMonetaryTotal>

</ubl:Invoice>

Note: This is an illustrative XML excerpt. It omits mandatory elements and is not a complete, submission-ready XRechnung invoice.

Understanding the Fields in an XRechnung Invoice

EN 16931 uses standardized Business Terms (BT) to identify individual invoice data elements. These help software systems interpret information consistently.

Business TermXML field (UBL)Description
BT-24CustomizationIDIdentifies the invoice specification
BT-1IDUnique invoice number
BT-2IssueDateDate the invoice was issued
BT-3InvoiceTypeCodeInvoice document type
BT-5DocumentCurrencyCodeInvoice currency
BT-10BuyerReferenceBuyer’s internal or routing reference
BT-110TaxAmountTotal VAT amount
BT-109TaxExclusiveAmountTotal invoice amount excluding VAT
BT-112TaxInclusiveAmountTotal invoice amount including VAT
BT-115PayableAmountOutstanding amount payable

A complete XRechnung invoice also contains seller and buyer information, electronic addresses, applicable tax details, payment information, and individual invoice line items.

What Is a Leitweg-ID in XRechnung?

A Leitweg-ID is a routing identifier used to direct electronic invoices to the appropriate German public authority. It is entered in the Buyer Reference field (BT-10) when invoicing relevant public sector organizations. Your contracting authority should provide this identifier.

For ordinary B2B transactions, a Leitweg-ID is not required. The BT-10 field itself is still mandatory in every XRechnung, though, so it can’t be left empty. Use your customer’s purchase order number or internal reference instead, or a placeholder if they don’t provide one.

You can explore complete UBL and CII invoice examples in the official KoSIT XRechnung Test Suite.

How to Open, View, and Validate an XRechnung File

If you’ve received an XRechnung invoice for the first time, you might be wondering why it doesn’t open like a regular PDF invoice.

Since XRechnung is a structured data file, you need a compatible application to display its contents in a readable invoice layout.

1. Open the XRechnung XML File

You can open an XRechnung file using a web browser, a text editor, or an XML editor such as Visual Studio Code.

These tools allow you to inspect the underlying invoice data. However, they don’t necessarily provide a user-friendly invoice preview or verify compliance with the XRechnung standard.

2. Use an XRechnung Viewer

An XRechnung viewer converts structured XML data into a human-readable invoice representation.

You can use:

  • The official ELSTER e-invoice viewer
  • Accounting software with built-in e-invoice viewing capabilities
  • KoSIT’s XRechnung visualization components
  • Dedicated third-party e-invoice viewers

When handling invoices containing sensitive financial or customer information, use trusted tools with appropriate data protection measures.

3. Validate the XRechnung File

An XML file isn’t automatically a valid XRechnung invoice simply because it contains invoice information.

Validation checks whether the document meets the applicable technical specifications and business rules.

The official KoSIT validator configuration for XRechnung can help identify issues such as:

  • Missing mandatory invoice fields
  • Incorrect XML structures
  • Invalid currency or country codes
  • Inconsistent VAT calculations
  • Incorrect invoice totals
  • Violations of XRechnung business rules

Validate your invoices before sending them to customers or public authorities to reduce the likelihood of rejection. Technical validation, however, does not guarantee that every tax or contractual requirement has been met.

Always retain the original structured invoice file, even if you generate a PDF representation for internal use.

XRechnung vs ZUGFeRD vs Peppol: What’s the Difference?

XRechnung, ZUGFeRD, and Peppol are frequently mentioned together in discussions about German e-invoicing. However, they serve different purposes.

XRechnung is a structured electronic invoice standard that uses XML without an accompanying visual invoice.

ZUGFeRD is an electronic invoice format commonly used to combine a human-readable PDF/A-3 document with embedded machine-readable XML data. Certain profiles also support XML-only use.

Peppol is an international network and framework for exchanging electronic business documents. It facilitates invoice transmission rather than serving solely as an invoice file format.

FeatureXRechnungZUGFeRDPeppol
Primary purposeStructured invoicingHuman- and machine-readable invoicingElectronic document exchange
Document formatXMLTypically PDF/A-3 with embedded XMLDepends on document specification
Human-readable layoutRequires a viewerIncluded in hybrid invoicesDepends on invoice format
Best suited forB2G and automated B2B invoicingB2B invoicingAutomated document transmission
EN 16931 compatibilityYesDepends on profileDepends on invoice specification

Which Option Should You Choose?

  • Invoicing German public authorities: Use XRechnung or another electronic invoice format accepted by the relevant authority.
  • Sharing human-readable invoices with structured data: Choose ZUGFeRD with a compliant profile to combine a readable PDF with embedded XML data.
  • Automating B2B invoicing and meeting German e-invoicing requirements: Use XRechnung, compliant ZUGFeRD, or another qualifying structured invoice format.
  • Exchanging invoices internationally: Use Peppol to securely transmit electronic invoices that follow supported specifications.

These options are not mutually exclusive. For example, you can generate an XRechnung invoice and transmit it through Peppol when the recipient and transmission service support it.

Is XRechnung Mandatory in Germany?

XRechnung itself is not universally mandatory in Germany. However, structured electronic invoicing is mandatory for certain transactions, and XRechnung is one of the established standards for meeting these requirements.

The applicable obligations depend on whether you’re invoicing a public authority or another business.

XRechnung Requirements for B2G Transactions

Since November 27, 2020, suppliers to Germany’s federal administration have generally been required to submit electronic invoices under the federal E-Invoicing Ordinance (E-RechV).

Exceptions apply, for example, invoices for direct orders of up to €1,000 net.

XRechnung is the standard generally used for federal government invoicing, although alternative formats are permitted if they meet the relevant legal, technical, and submission requirements.

Requirements at state and municipal levels may differ, so suppliers should check the conditions specified by their contracting authority.

Germany’s B2B E-Invoicing Timeline

Germany introduced its domestic B2B e-invoicing mandate on January 1, 2025, with a phased transition for invoice issuance.

January 1, 2025 — Receiving e-invoices

Domestic businesses must be able to receive structured e-invoices.

December 31, 2026 — General transition period ends

Businesses can generally continue issuing paper invoices or agreed non-structured electronic invoices until this date.

January 1, 2027 — Large business issuance deadline

Businesses with prior-year turnover exceeding €800,000 generally need to issue structured e-invoices for qualifying transactions, subject to exceptions and the temporary EDI rule.

January 1, 2028 — Remaining transition periods end

Structured e-invoice issuance becomes mandatory across eligible domestic B2B transactions, subject to statutory exemptions.

Businesses with prior-year turnover of €800,000 or less benefit from an extended transition period until December 31, 2027. Certain existing EDI invoicing arrangements may also continue until that date.

Are There Any Exceptions?

Germany’s domestic B2B e-invoicing mandate does not cover every transaction.

The mandate doesn’t apply to B2C sales at all. Within B2B, it also exempts invoices with a gross amount of €250 or less, transport tickets, certain tax-exempt transactions, and invoices issued by businesses under Germany’s small business VAT scheme (Kleinunternehmerregelung).

However, businesses under the small business VAT scheme must still be capable of receiving e-invoices.

For more information, refer to the German Federal Ministry of Finance’s official e-invoicing FAQ.

Do Foreign Businesses Need to Use XRechnung?

Selling products or services to customers in Germany does not automatically make your business subject to Germany’s domestic B2B e-invoicing mandate.

The mandate generally applies to transactions between businesses established in Germany.

A foreign company registered for German VAT but without an establishment in Germany is generally not subject to the domestic B2B e-invoice issuance obligation solely because of that VAT registration. However, if your company has a German fixed establishment involved in the transaction, the requirements may apply.

Foreign suppliers invoicing German public authorities must also consider separate B2G electronic invoicing rules.

For international eCommerce businesses, it’s important to distinguish between selling into Germany, operating an established business in Germany, and supplying German government organizations.

Consult a qualified tax advisor to determine which obligations apply to your business.

XRechnung Versions: XRechnung 3.0 vs XRechnung 4.0

As of November 2026, XRechnung 3.0 remains the current normative standard. It came into effect on February 1, 2024, and is expected to remain valid until at least July 31, 2027.

KoSIT published a preliminary specification for XRechnung 4.0 on September 15, 2026, following the revision of the European electronic invoicing standard EN 16931.

The upcoming version introduces more than 50 additional Business Terms and several changes, including:

  • Support for multiple buyer references
  • Expanded delivery information
  • References to multiple orders and deliveries
  • Structured early payment discount information
  • Expanded support for XML attachments

The final XRechnung 4.0 technical bundle is expected in spring 2027. However, the preliminary specification is not intended for production use.

For now, businesses should continue using the current XRechnung 3.0 standard and keep their invoicing software updated.

You can track upcoming releases on the official XRechnung versions and bundles page.

How to Generate XRechnung Invoices in WooCommerce

If your store is established in Germany and sells to other German businesses, or if you invoice German public authorities, you need to issue structured e-invoices. For B2C or cross-border sales, XRechnung is optional, but it can still speed up payment from business customers who process invoices automatically. Either way, generating e-invoices directly from your WooCommerce order data saves manual work.

The WooCommerce PDF Invoices & Packing Slips plugin by WebToffee supports multiple electronic invoicing formats, including German XRechnung. With the plugin, you can:

  • Generate XRechnung invoices (UBL format).
  • Automatically generate PDF invoices from WooCommerce orders.
  • Add VAT and other relevant tax information to invoices.
  • Configure custom invoice numbering sequences.
  • Generate credit notes and packing slips.
  • Reduce manual invoice preparation.

Before sending your first invoices, check a sample with the KoSIT validator to confirm your settings produce a valid XRechnung.

Frequently Asked Questions

What is XRechnung?

XRechnung is Germany’s standard for structured electronic invoices. It is a pure XML format based on EN 16931, maintained by KoSIT, and the standard format for invoices to German public authorities

How do you pronounce XRechnung?

XRechnung is pronounced approximately as “iks-rekh-noong.”

Is XRechnung the same as an XML invoice?

XRechnung is a specific type of XML invoice that follows EN 16931 and Germany-specific business rules. Not every XML invoice qualifies as an XRechnung invoice.

What is the difference between XRechnung and ZUGFeRD?

XRechnung is a structured XML-only invoice format. ZUGFeRD typically combines a readable PDF with embedded XML invoice data. Both can support German electronic invoicing requirements.

Can I convert an XRechnung file to PDF?

Yes. An XRechnung viewer can generate a readable PDF representation of the invoice. However, the original XML file should be retained as the structured electronic invoice.

Is Peppol mandatory for XRechnung?

No. Peppol is one method of transmitting electronic invoices. Depending on the recipient and applicable requirements, XRechnung invoices can also be exchanged through email, submission portals, or other supported channels.

Is a PDF invoice compliant with Germany’s 2027 e-invoicing requirements?

A standard PDF invoice does not qualify as a structured e-invoice. A hybrid PDF containing compliant XML data, such as an appropriate ZUGFeRD invoice, can meet the requirements. Transition rules and statutory exceptions may still permit ordinary PDFs in certain circumstances.

Conclusion

XRechnung is becoming an increasingly important invoicing standard for businesses operating in Germany. Its structured XML format allows businesses to automate invoice processing, reduce manual data entry, and support electronic invoicing compliance.

With Germany’s 2027 issuance deadline approaching, businesses should review their existing invoicing processes, confirm their obligations, and adopt software that supports structured electronic invoices.

Preparing now can help businesses avoid last-minute implementation challenges and establish more efficient invoicing workflows.

Article by

Writer at WebToffee. I focus on WooCommerce and Shopify store migration, import/export workflows, and eCommerce data management, breaking down technical concepts into clear, easy-to-follow guides for store owners.

Got any query? Please leave a comment or reach out to our support

Your email address will not be published. Required fields are marked *

Google Preferred Source

Automate PDF Invoices Before the BFCM Order Rush