# XML Invoice Format: A Complete Example, UBL vs CII and Formats per Country

> A complete XML invoice example that passes Peppol validation, UBL vs CII, the XML format each country requires in 2026, and how to open and validate your file.
>
> Source: https://e-invoice.be/blog/xml-invoicing

A complete XML invoice that passes Peppol validation. The mandatory fields, how UBL and CII differ, which XML format each country requires in 2026, and how to open and validate your file.

![XML Invoice Format: A Complete Example, UBL vs CII and Formats per Country](https://e-invoice.be/blog/og/xml-invoicing.png)

An XML invoice is an invoice where every field sits inside a named tag instead of being printed on a page. The invoice number is in one tag, the issue date in another, each line item in its own block. Because every value is labelled, software reads the file directly. No OCR, no retyping, no guessing which number is the VAT. In Europe the tag names come from a standard, almost always UBL 2.1 or UN/CEFACT CII.

A few lines from a real XML invoice

```
<cbc:ID>INV-2026-0042</cbc:ID>
<cbc:IssueDate>2026-03-01</cbc:IssueDate>
<cbc:DocumentCurrencyCode>EUR</cbc:DocumentCurrencyCode>
<cac:LegalMonetaryTotal>
  <cbc:PayableAmount currencyID="EUR">3872.00</cbc:PayableAmount>
</cac:LegalMonetaryTotal>
```

XML invoicing in 30 seconds (November 2026)

- **Two syntaxes carry almost everything:** UBL 2.1 (OASIS) and CII (UN/CEFACT). Both encode the same EN 16931 data.
- **Peppol uses UBL 2.1** with the Peppol BIS Billing 3.0 profile. UBL 2.5 (August 2026) is the latest OASIS release. There is no UBL 3.0.
- **Some countries have their own XML:** FatturaPA in Italy, FA(3) in Poland's KSeF, CFDI in Mexico.
- **Hybrid PDFs** (ZUGFeRD, Factur-X) embed a CII XML file inside a PDF/A-3.
- **A PDF alone is not an e-invoice** under the B2B mandates in Belgium, Germany, France, Poland or Italy.

This guide gives you a complete invoice you can copy, the list of fields that are legally mandatory, the differences between the XML dialects you will meet, the format each country expects, and the validation layers your file has to survive before it reaches a customer.

## 1. A complete XML invoice example

Below is a full UBL 2.1 invoice that follows the Peppol BIS Billing 3.0 profile. This is not a trimmed illustration. It contains every element the Peppol validation rules require, so you can paste it into a file, change the values, and validate it. One seller, one buyer, one line item, 21% Belgian VAT. We validated it on 18 November 2026 against the UBL 2.1 XSD, the EN 16931 rules and the Peppol BIS Billing 3.0 rules: zero errors, zero warnings.

Both parties use scheme 0208, the Belgian enterprise number (KBO/BCE). Peppol checks its mod-97 check digits, so a made-up number such as 0123456789 fails rule PEPPOL-COMMON-R043. For a company in another country, swap in its own scheme, for example 0225 (SIREN) in France or 0106 (KvK) in the Netherlands.

```
<?xml version="1.0" encoding="UTF-8"?>
<Invoice xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"
         xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
         xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2">

  <!-- Which rulebook this invoice follows -->
  <cbc:CustomizationID>urn:cen.eu:en16931:2017#compliant#urn:fdc:peppol.eu:2017:poacc:billing:3.0</cbc:CustomizationID>
  <cbc:ProfileID>urn:fdc:peppol.eu:2017:poacc:billing:01:1.0</cbc:ProfileID>

  <!-- Header -->
  <cbc:ID>INV-2026-0042</cbc:ID>
  <cbc:IssueDate>2026-03-01</cbc:IssueDate>
  <cbc:DueDate>2026-03-31</cbc:DueDate>
  <cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>
  <cbc:DocumentCurrencyCode>EUR</cbc:DocumentCurrencyCode>
  <cbc:BuyerReference>PO-8891</cbc:BuyerReference>

  <!-- Seller -->
  <cac:AccountingSupplierParty>
    <cac:Party>
      <cbc:EndpointID schemeID="0208">0123456749</cbc:EndpointID>
      <cac:PartyName>
        <cbc:Name>Webbureau Leuven BV</cbc:Name>
      </cac:PartyName>
      <cac:PostalAddress>
        <cbc:StreetName>Diestsestraat 12</cbc:StreetName>
        <cbc:CityName>Leuven</cbc:CityName>
        <cbc:PostalZone>3000</cbc:PostalZone>
        <cac:Country><cbc:IdentificationCode>BE</cbc:IdentificationCode></cac:Country>
      </cac:PostalAddress>
      <cac:PartyTaxScheme>
        <cbc:CompanyID>BE0123456749</cbc:CompanyID>
        <cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
      </cac:PartyTaxScheme>
      <cac:PartyLegalEntity>
        <cbc:RegistrationName>Webbureau Leuven BV</cbc:RegistrationName>
        <cbc:CompanyID schemeID="0208">0123456749</cbc:CompanyID>
      </cac:PartyLegalEntity>
    </cac:Party>
  </cac:AccountingSupplierParty>

  <!-- Buyer -->
  <cac:AccountingCustomerParty>
    <cac:Party>
      <cbc:EndpointID schemeID="0208">0987654394</cbc:EndpointID>
      <cac:PartyName>
        <cbc:Name>Bakkerij Peeters NV</cbc:Name>
      </cac:PartyName>
      <cac:PostalAddress>
        <cbc:StreetName>Grote Markt 3</cbc:StreetName>
        <cbc:CityName>Antwerpen</cbc:CityName>
        <cbc:PostalZone>2000</cbc:PostalZone>
        <cac:Country><cbc:IdentificationCode>BE</cbc:IdentificationCode></cac:Country>
      </cac:PostalAddress>
      <cac:PartyLegalEntity>
        <cbc:RegistrationName>Bakkerij Peeters NV</cbc:RegistrationName>
        <cbc:CompanyID schemeID="0208">0987654394</cbc:CompanyID>
      </cac:PartyLegalEntity>
    </cac:Party>
  </cac:AccountingCustomerParty>

  <!-- How the buyer should pay -->
  <cac:PaymentMeans>
    <cbc:PaymentMeansCode>30</cbc:PaymentMeansCode>
    <cac:PayeeFinancialAccount>
      <cbc:ID>BE68539007547034</cbc:ID>
    </cac:PayeeFinancialAccount>
  </cac:PaymentMeans>

  <!-- VAT breakdown: one subtotal per rate -->
  <cac:TaxTotal>
    <cbc:TaxAmount currencyID="EUR">672.00</cbc:TaxAmount>
    <cac:TaxSubtotal>
      <cbc:TaxableAmount currencyID="EUR">3200.00</cbc:TaxableAmount>
      <cbc:TaxAmount currencyID="EUR">672.00</cbc:TaxAmount>
      <cac:TaxCategory>
        <cbc:ID>S</cbc:ID>
        <cbc:Percent>21</cbc:Percent>
        <cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
      </cac:TaxCategory>
    </cac:TaxSubtotal>
  </cac:TaxTotal>

  <!-- Document totals -->
  <cac:LegalMonetaryTotal>
    <cbc:LineExtensionAmount currencyID="EUR">3200.00</cbc:LineExtensionAmount>
    <cbc:TaxExclusiveAmount currencyID="EUR">3200.00</cbc:TaxExclusiveAmount>
    <cbc:TaxInclusiveAmount currencyID="EUR">3872.00</cbc:TaxInclusiveAmount>
    <cbc:PayableAmount currencyID="EUR">3872.00</cbc:PayableAmount>
  </cac:LegalMonetaryTotal>

  <!-- Line item -->
  <cac:InvoiceLine>
    <cbc:ID>1</cbc:ID>
    <cbc:InvoicedQuantity unitCode="HUR">40</cbc:InvoicedQuantity>
    <cbc:LineExtensionAmount currencyID="EUR">3200.00</cbc:LineExtensionAmount>
    <cac:Item>
      <cbc:Name>Website redesign</cbc:Name>
      <cac:ClassifiedTaxCategory>
        <cbc:ID>S</cbc:ID>
        <cbc:Percent>21</cbc:Percent>
        <cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
      </cac:ClassifiedTaxCategory>
    </cac:Item>
    <cac:Price>
      <cbc:PriceAmount currencyID="EUR">80.00</cbc:PriceAmount>
    </cac:Price>
  </cac:InvoiceLine>

</Invoice>
```

Four details in this file trip up most first attempts:

- **Element order is fixed.** UBL is defined by an XSD schema with a strict sequence. Putting `cac:InvoiceLine` before `cac:LegalMonetaryTotal` is not a style choice. It breaks the file.
- **`CustomizationID` is the rulebook.** It tells the receiver which validation rules apply. Get it wrong and the invoice is rejected by the network before a human sees it.
- **Every amount needs a currency attribute.** A bare `3872.00` without `currencyID` fails schema validation.
- **The VAT breakdown must reconcile.** `TaxSubtotal/TaxableAmount` has to equal the sum of the line net amounts at that rate. Cent rounding differences are the single most common rejection we see.

Paste this file into our [Invoice Viewer](https://e-invoice.be/peppol-invoice-viewer) to see it rendered as a readable document, or into the [Peppol Validator](https://e-invoice.be/peppol-validator) to run the real rule set against it. For a field-by-field walkthrough of every UBL element, including VAT categories, unit codes and attachments, see our [UBL invoice format guide](https://e-invoice.be/blog/ubl-format-guide). To produce files like this from code, our [Peppol API developer resources](https://e-invoice.be/developers) list the SDKs and the sandbox.

## 2. The fields that are legally mandatory

UBL defines hundreds of optional elements. EN 16931, the European standard behind every compliant e-invoice, narrows that down to a core set that must always be present. Each field has a BT number in the standard. These are the ones you cannot leave out of a Peppol invoice. To browse the optional elements as well, open the [interactive UBL 2.1 schema explorer](https://e-invoice.be/ubl-format-explorer).

| EN 16931 field                     | UBL element                               | Note                                                      |
| ---------------------------------- | ----------------------------------------- | --------------------------------------------------------- |
| BT-24 Specification identifier     | cbc:CustomizationID                       | Fixed string for Peppol BIS Billing 3.0                   |
| BT-1 Invoice number                | cbc:ID                                    | Must be unique per seller                                 |
| BT-2 Issue date                    | cbc:IssueDate                             | Format YYYY-MM-DD, no time component                      |
| BT-3 Invoice type code             | cbc:InvoiceTypeCode                       | 380 for a commercial invoice, 381 for a credit note       |
| BT-5 Currency                      | cbc:DocumentCurrencyCode                  | ISO 4217 code                                             |
| BT-34 / BT-49 Electronic addresses | cbc:EndpointID                            | Peppol identifiers for seller and buyer, both required    |
| BT-27 / BT-44 Legal names          | cac:PartyLegalEntity/cbc:RegistrationName | The registered name, not a trading name                   |
| BT-40 / BT-55 Country codes        | cac:Country/cbc:IdentificationCode        | Two-letter ISO 3166 code on both addresses                |
| BT-106 to BT-115 Totals            | cac:LegalMonetaryTotal                    | Line total, total without VAT, total with VAT, amount due |
| BG-23 VAT breakdown                | cac:TaxTotal/cac:TaxSubtotal              | One subtotal per VAT rate and category                    |

Peppol adds two rules on top of EN 16931 that catch people out. A buyer reference or a purchase order reference is mandatory, so an invoice with neither is rejected. And both electronic addresses must be present, even though EN 16931 itself treats them as optional. If you are mapping your own data model to the standard, our [EN 16931 field mapper](https://e-invoice.be/en16931-mapper) shows the full BT-to-UBL correspondence.

## 3. XML invoice formats: UBL, CII and how to tell them apart

"XML invoice" is not one format. It is a family of incompatible schemas that all happen to use XML. If a customer sends you a file and you do not know what it is, the root element and the customization identifier tell you within seconds.

| Format                   | Root element                            | How to recognise it                                                  |
| ------------------------ | --------------------------------------- | -------------------------------------------------------------------- |
| UBL 2.1 / Peppol BIS 3.0 | <Invoice>                               | CustomizationID contains peppol.eu:2017:poacc:billing:3.0            |
| CII (UN/CEFACT D16B)     | <rsm:CrossIndustryInvoice>              | Tag prefixes rsm, ram and udt instead of cac and cbc                 |
| XRechnung (Germany)      | <Invoice> or <rsm:CrossIndustryInvoice> | Specification identifier contains xrechnung_3.0                     |
| ZUGFeRD / Factur-X       | None. It is a PDF.                      | PDF/A-3 with an attachment named factur-x.xml or zugferd-invoice.xml |
| FatturaPA (Italy)        | <p:FatturaElettronica>                  | A versione attribute of FPA12 or FPR12                               |
| FA(3) (Poland, KSeF)     | <Faktura>                               | A KodFormularza element with system code FA (3)                      |

UBL and CII carry the same EN 16931 data with different tag names. That means a mechanical conversion between them is possible, and it is what most Access Points do internally. XRechnung is not a third syntax. It is a national profile that narrows EN 16931 and can be expressed in either UBL or CII. FatturaPA sits outside EN 16931 entirely and needs a real transformation, not a rename. The same goes for Poland's FA(3).

### UBL vs CII at a glance

Both syntaxes are official bindings of EN 16931, so neither is "more compliant" than the other. The choice usually comes from the network or the country, not from you.

|                                | UBL 2.1                                                                                                | CII (D16B)                                                                               |
| ------------------------------ | ------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------------- |
| Maintained by                  | OASIS (latest release UBL 2.5, August 2026)                                                            | UN/CEFACT                                                                                |
| Document types                 | Separate Invoice and CreditNote schemas, plus orders, despatch advice and 60+ other business documents | One CrossIndustryInvoice schema. The type code (380, 381) tells invoice from credit note |
| Structure                      | Flat. Header, parties, totals and lines sit close to the root                                          | Deeper. Data is grouped under agreement, delivery and settlement blocks                  |
| Used by                        | Peppol (Belgium, Netherlands, Nordics, Australia, Singapore, Japan), XRechnung UBL, Croatia, Romania   | ZUGFeRD, Factur-X, XRechnung CII                                                         |
| Accepted in France and Germany | Yes                                                                                                    | Yes                                                                                      |

For a field-by-field UBL walkthrough, read the [UBL format guide](https://e-invoice.be/blog/ubl-format-guide). For the CII side inside a hybrid PDF, including all ZUGFeRD profiles and version 2.5.2, read the [ZUGFeRD format guide](https://e-invoice.be/blog/zugferd-format-guide) (in German) or the [Factur-X format guide](https://e-invoice.be/blog/factur-x-format) (in French).

Not sure what you have? Drop the file into our [format detector](https://e-invoice.be/format-detector). To pull the XML out of a hybrid PDF, use the [ZUGFeRD XML extractor](https://e-invoice.be/zugferd-xml-extractor). To move a CII file onto Peppol, use the [CII to UBL converter](https://e-invoice.be/cii-to-ubl-converter).

## 4. Which XML invoice format each country requires

Most countries do not mandate "XML" by name. They mandate a structured format, a delivery channel, or both. The table shows the state of play on 18 November 2026 for the countries our customers ask about most. Dates are for domestic B2B invoices.

| Country     | XML format                                                    | Syntax                   | B2B status (Nov 2026)                                                                                                              |
| ----------- | ------------------------------------------------------------- | ------------------------ | ---------------------------------------------------------------------------------------------------------------------------------- |
| Belgium     | Peppol BIS Billing 3.0                                        | UBL 2.1                  | Mandatory over Peppol since 1 January 2026                                                                                         |
| Germany     | XRechnung 3.0, or ZUGFeRD from the BASIC profile              | UBL or CII               | Receiving since 2025. Sending from 2027 above €800,000 turnover, from 2028 for everyone                                            |
| France      | UBL, CII or Factur-X via an approved platform                 | UBL or CII               | Receiving for all since 1 September 2026. Sending: large and mid-size companies since 1 September 2026, SMEs from 1 September 2027 |
| Italy       | FatturaPA via the SdI exchange                                | National XML             | Mandatory since 2019                                                                                                               |
| Poland      | FA(3) via KSeF                                                | National XML             | Mandatory since 1 February 2026 (largest taxpayers) and 1 April 2026 (others). Smallest businesses from 2027                       |
| Croatia     | HR CIUS (EN 16931)                                            | UBL 2.1                  | Mandatory for VAT payers since 1 January 2026                                                                                      |
| Romania     | CIUS-RO via RO e-Factura                                      | UBL 2.1                  | Mandatory since 2024                                                                                                               |
| Spain       | Facturae (public sector). UBL, CII or EDIFACT planned for B2B | National XML, UBL or CII | B2B planned from October 2027 (turnover above €8 million), October 2028 for others                                                 |
| Netherlands | Peppol BIS Billing 3.0 / SI-UBL 2.0                           | UBL 2.1                  | Public sector only. B2B announced for 1 July 2030                                                                                  |
| Denmark     | OIOUBL or Peppol BIS Billing 3.0                              | UBL                      | Public sector only. No B2B transaction mandate                                                                                     |

Two patterns stand out. Peppol countries all converge on UBL 2.1, so one integration covers them. Countries with a central clearance platform, like Italy and Poland, tend to keep their own XML schema. For every EU country, with phases, thresholds and official sources, see our [e-invoicing mandate matrix](https://e-invoice.be/e-invoicing-mandate-matrix).

### Outside Europe

- **Australia, New Zealand, Singapore, Japan:** Peppol with national PINT specifications, all in UBL 2.1.
- **Saudi Arabia:** ZATCA e-invoices are UBL 2.1 XML with a cryptographic stamp and QR code.
- **Malaysia:** MyInvois accepts UBL 2.1 in XML or JSON.
- **Mexico:** CFDI 4.0, a national XML format stamped by a certified provider.
- **India:** the e-invoice system uses JSON, not XML.

Primary specifications: [Peppol BIS Billing 3.0](https://docs.peppol.eu/poacc/billing/3.0/), [OASIS UBL](https://www.oasis-open.org/committees/ubl/), [XRechnung (KoSIT)](https://xeinkauf.de/xrechnung/), [KSeF (Polish Ministry of Finance)](https://ksef.podatki.gov.pl/).

Which format do you actually need?

On the Peppol network, the answer is always UBL 2.1 with the Peppol BIS Billing 3.0 profile (or the PINT variant of that country). A ZUGFeRD or Factur-X PDF emailed to a customer does not satisfy the Belgian B2B mandate. The invoice has to travel over Peppol as structured XML. If you sell into several countries, pick a provider that converts between UBL, CII and the national formats for you.

## 5. How to open and read an XML invoice

An XML invoice is plain text, so you can always open it. Whether you can read it is another matter. Pick the tool by what you need to do.

- **See the raw data:** any text editor (Notepad, TextEdit, VS Code) or a web browser. Browsers show the tag tree without styling. Good for checking one value, useless for a customer.
- **Read it as an invoice:** a viewer applies a stylesheet and renders a normal invoice layout. Use our [Peppol Invoice Viewer](https://e-invoice.be/peppol-invoice-viewer) for UBL, the [XRechnung Viewer](https://e-invoice.be/xrechnung-viewer) for German files, or the [ZUGFeRD Viewer](https://e-invoice.be/zugferd-viewer) for hybrid PDFs.
- **Get a PDF for your archive or a colleague:** convert it with the [Peppol to PDF converter](https://e-invoice.be/peppol-to-pdf). Keep the XML as well. In most countries the structured file is the legal original, and Germany requires you to keep it for 8 years (§ 14b UStG).
- **Book it:** import the XML into your accounting software or ERP. This is the point of XML invoicing. No retyping.
- **Open it in Excel:** Excel can import XML, but it flattens nested blocks such as invoice lines and VAT subtotals into awkward rows. Use a viewer for reading and Excel only for bulk analysis.

## 6. XML vs. PDF vs. EDI

The line that matters for compliance is structured versus unstructured. A PDF looks like an invoice, but to software it is a picture of text. It has no idea which number is the total and which is the VAT.

| Method                      | Format                         | Machine-readable?      | Valid under the Belgian mandate? |
| --------------------------- | ------------------------------ | ---------------------- | -------------------------------- |
| XML invoice over Peppol     | Structured (UBL, CII)          | Yes, fully             | Yes                              |
| EDI invoice                 | Structured (EDIFACT, ANSI X12) | Yes, fully             | Only if converted to Peppol      |
| PDF invoice by email        | Unstructured (visual document) | No, needs OCR          | No                               |
| Hybrid (ZUGFeRD / Factur-X) | PDF with embedded XML          | Yes, via the XML layer | Not by email                     |

Hybrid formats are a useful bridge during a transition. Recipients with modern software extract the XML, everyone else reads the PDF. They are widely used in Germany and France. They are not a substitute for Peppol delivery in Belgium. If you need to show an XML invoice to a human, our [Peppol to PDF converter](https://e-invoice.be/peppol-to-pdf) renders it as a readable document. If your billing tool only produces PDFs, we can [convert your PDF invoices to Peppol UBL](https://e-invoice.be/peppol-pdf-conversion) and send them for you. To check which fields of a PDF map to UBL, run it through the [free PDF to UBL analyzer](https://e-invoice.be/pdf-to-ubl).

## 7. How to validate an XML invoice

A file that opens without error in a browser is not a valid invoice. Peppol invoices pass through three independent validation layers, and each one rejects different things. Most developers discover the second and third layers the hard way.

1

#### XSD schema: is the shape right?

Checks that elements exist, are spelled correctly, sit in the required order and hold the right data type. A typical failure reads cvc-complex-type.2.4.a: Invalid content was found starting with element. That almost always means an element is out of sequence.

2

#### EN 16931 Schematron: do the numbers make sense?

Business rules with BR codes. BR-16 requires at least one invoice line. BR-CO-10 requires the sum of line net amounts to equal the stated line total. BR-CO-15 requires the total with VAT to equal the total without VAT plus the VAT amount. BR-S-08 requires the standard-rate taxable amount to match the lines at that rate.

3

#### Peppol BIS Schematron: does the network accept it?

Rules with PEPPOL-EN16931 codes. R003 requires a buyer reference or a purchase order reference. R010 and R020 require the buyer and seller electronic addresses. R004 requires the exact Peppol specification identifier. These rules exist only on Peppol, so a file that is perfectly valid EN 16931 can still be rejected here.

4

#### Delivery check: can the recipient receive it?

Not validation of the file, but the last thing that stops a send. The recipient's Peppol ID has to be registered in an SMP for the invoice document type. Look the identifier up before you send with our [Peppol ID checker](https://e-invoice.be/peppol-radar).

Rounding is the number one rejection cause

If you calculate line totals at full float precision and round only the document total, BR-CO-10 will fail by one cent. Round each line amount to two decimals first, then sum the rounded values. Do the same for the VAT breakdown. This single change eliminates most validation failures we see from new integrations.

## 8. Creating XML invoices without writing XML

Hand-building UBL is possible, and the example above shows it is not mysterious. It is still rarely the right use of your time. Namespace handling, element ordering, VAT edge cases and Schematron updates are ongoing maintenance, not a one-off task. Most teams send flat data to an Access Point and let it produce and validate the XML. Scripts and CI pipelines can do the same with the [open-source Peppol CLI](https://e-invoice.be/peppol-cli).

With the e-invoice.be API you post plain JSON. No namespaces, no tag ordering, no Schematron.

```
POST https://api.e-invoice.be/api/documents/
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json

{
  "document_type": "INVOICE",
  "invoice_id": "INV-2026-0042",
  "invoice_date": "2026-03-01",
  "due_date": "2026-03-31",
  "currency": "EUR",
  "vendor_name": "Webbureau Leuven BV",
  "vendor_tax_id": "BE0123456749",
  "vendor_address": "Diestsestraat 12, 3000 Leuven, BE",
  "customer_name": "Bakkerij Peeters NV",
  "customer_tax_id": "BE0987654394",
  "customer_peppol_id": "0208:0987654394",
  "items": [
    {
      "description": "Website redesign",
      "quantity": 40,
      "unit_price": 80.00,
      "tax_rate": 21.00
    }
  ]
}
```

That request creates the document and builds a UBL invoice like the one in section 1. Two more calls finish the job:

- `POST /api/documents/{document_id}/send` delivers it over Peppol.
- `GET /api/documents/{document_id}/ubl` returns the generated XML for your archive.

The API runs all three validation layers before delivery and returns the rule code if anything fails, so you fix problems before the invoice leaves your system. Already have UBL from your own system? Post it to `/api/documents/ubl` instead. SDKs exist for TypeScript, Python, PHP, Ruby and Java/Kotlin, and there is a CLI (`brew install e-invoice-be/tap/peppol-cli`). Incoming invoices arrive as the same flat JSON through a webhook, with the original XML attached. To look up those invoices from Claude, ChatGPT or Cursor, connect our [Peppol MCP server for AI assistants](https://e-invoice.be/mcp).

If you are not a developer, you never touch any of this. Create an account, register your company, and send invoices from the dashboard or by email. The account and your Peppol ID are free. Every document you send or receive uses prepaid credits, from €0.25 per document. No subscription, prepaid credits, pure pay per use. Only have PDFs? We can [convert your PDF invoices to UBL and send them](https://e-invoice.be/peppol-pdf-conversion) for 1 extra credit per PDF. See the [API integration guide](https://e-invoice.be/blog/e-invoicing-api-integration) for full code examples, or the [Peppol registration guide](https://e-invoice.be/blog/peppol-registration) to get set up.

## 9. Frequently asked questions

### What is an XML invoice?

An XML invoice is an invoice where every field is stored inside a named tag instead of being printed on a page. The invoice number sits in one tag, the issue date in another, each line item in its own block. Because the meaning of every value is labelled, accounting software, ERP systems and tax authorities can read the file directly, with no OCR and no retyping. In Europe the tag names are set by a standard, usually UBL 2.1 or UN/CEFACT CII.

### What does an XML invoice file look like?

It is a plain text file you can open in Notepad or any code editor. It starts with an XML declaration, then a root element such as <Invoice>, then nested elements like <cbc:ID>INV-2026-0042</cbc:ID> and <cbc:IssueDate>2026-03-01</cbc:IssueDate>. A typical Peppol invoice is 100 to 300 lines long. The full example in this article is a working Peppol BIS Billing 3.0 invoice you can copy and validate.

### Which XML invoice format do I need?

It depends on the country of your customer. On the Peppol network, which covers Belgium, the Netherlands, the Nordics and a growing list of countries outside Europe, you need UBL 2.1 following the Peppol BIS Billing 3.0 profile. Germany accepts XRechnung (UBL or CII) and ZUGFeRD from the BASIC profile up. France accepts UBL, CII and Factur-X through an approved platform. Italy (FatturaPA) and Poland (FA(3) in KSeF) use their own national XML schemas. If you are unsure what you received, check the root element and the CustomizationID.

### What is the difference between UBL and CII?

UBL (OASIS) and CII (UN/CEFACT) are two XML syntaxes for the same EN 16931 invoice data. UBL uses the root element <Invoice> with cbc and cac prefixes. CII uses <rsm:CrossIndustryInvoice> with ram and udt prefixes and nests the data deeper. Peppol uses UBL. ZUGFeRD and Factur-X use CII. XRechnung and the French reform accept both. Because the data model is the same, a CII invoice can be converted to UBL without losing EN 16931 content.

### How do I open an XML invoice?

Any text editor or web browser opens the file, but you will see raw tags, not an invoice. To read it as a document, use a viewer that applies a stylesheet, such as our free Peppol Invoice Viewer for UBL or the XRechnung Viewer for German files. Your accounting software can also import it directly. If the XML sits inside a PDF (ZUGFeRD or Factur-X), extract the embedded file first or open it in a ZUGFeRD viewer.

### How do I validate an XML invoice?

Validation happens in three layers. First the XSD schema checks that the file is well formed and that elements appear in the right order. Then the EN 16931 Schematron checks the business rules, such as whether the line totals add up to the invoice total. Finally the Peppol BIS Schematron checks network specific rules, such as the requirement for a buyer reference. A file can pass the XSD and still fail the Schematron, which is the most common surprise for developers.

### How do I create an XML invoice without writing XML?

Send flat JSON to an Access Point API and let it build the XML. With the e-invoice.be API you post fields like vendor_name, customer_name, invoice_id and an items array. The Access Point generates valid UBL 2.1, runs all three validation layers, and delivers the file over Peppol. You can still download the generated XML afterwards if you need it for your archive.

### What is the difference between a PDF invoice and an XML invoice?

A PDF is a picture of an invoice. Software can see the pixels but does not know which number is the VAT and which is the total, so it needs OCR or manual entry. An XML invoice labels every value explicitly, so it can be booked automatically. Under the B2B mandates in Belgium, Germany, France and Poland a PDF sent by email is not a valid e-invoice, even if the PDF was generated by accounting software.

### Is XML invoicing the same as e-invoicing?

XML invoicing is one form of e-invoicing, and by far the most common one in Europe. E-invoicing means any exchange of invoices in a structured format. EDI formats such as EDIFACT are structured but are not XML. Scanned invoices and PDFs are not structured at all, so they are not e-invoices in the legal sense.

### Is XML invoicing mandatory?

In a growing number of countries, yes. As of November 2026, B2B e-invoicing is mandatory in Italy (since 2019), Romania (2024), Belgium and Croatia (January 2026), Poland (February and April 2026) and France (issuing from September 2026 for large and mid-size companies). Germany requires every business to receive e-invoices since 2025 and to send them from 2027 or 2028. The laws name a structured format, not XML as such, but in practice almost every compliant format is XML. The EU ViDA package makes structured e-invoicing the norm for intra-EU trade from July 2030.

### What is the latest UBL version?

The latest OASIS release is UBL 2.5, approved in August 2026. There is no UBL 3.0. Peppol BIS Billing 3.0 still uses UBL 2.1, so every Peppol invoice you send or receive today is UBL 2.1.

### Free XML invoice tools

- [Peppol Validator](https://e-invoice.be/peppol-validator) Run the real EN 16931 and Peppol rule set against your XML file
- [Invoice Viewer](https://e-invoice.be/peppol-invoice-viewer) View and inspect UBL XML invoices visually
- [Invoice Generator](https://e-invoice.be/peppol-invoice-generator) Fill in a form and download a valid UBL XML invoice
- [Format Detector](https://e-invoice.be/format-detector) Detect whether your XML file is UBL, CII, ZUGFeRD or Factur-X
- [CII to UBL Converter](https://e-invoice.be/cii-to-ubl-converter) Convert Cross-Industry Invoice XML to UBL format
- [XRechnung Viewer](https://e-invoice.be/xrechnung-viewer) View XRechnung XML invoices for the German market

### Send XML e-invoices without building UBL yourself

You send the data. We generate the XML, run every validation layer, and deliver over Peppol. The account and your Peppol ID are free. Every document sent or received uses prepaid credits, from €0.25 per document. No subscription.

[Create account](https://app.e-invoice.be/register) [View API docs](https://e-invoice.be/peppol-api)

![Tom Van Asbroeck](https://e-invoice.be/tom.jpeg)

Tom Van Asbroeck

Co-founder, Peppol & tax expert

Tom is a co-founder of e-invoice.be and runs its operations. He helps companies and software vendors connect to Peppol and answers their questions on e-invoicing rules and VAT.

- Co-founder of e-invoice.be, a certified Peppol Access Point
- Hosts the 15-minute Peppol discovery calls
- Follows the e-invoicing mandates in Belgium, France and Germany
[LinkedIn](https://www.linkedin.com/in/tom-van-asbroeck-8a141a236/)

## Moving from your own XML format to Peppol? 15 min to plan the mapping.

If you're already generating XML, the work isn't starting over, it's mapping. We'll walk through what changes for UBL/Peppol BIS 3.0 and what doesn't.

Vendor-neutral. No obligation to switch platforms.

![Portrait of Tom Van Asbroeck](https://e-invoice.be/tom.jpeg)

Hosted by Tom Van Asbroeck

Peppol & tax expert
