Formats and content
Leitweg-ID: Structure, How to Get It and Typical Mistakes
The Leitweg-ID routes your invoice to the right office of a public authority. It goes into the field BT-10 of the XRechnung and is given to you by the contracting authority.
Last reviewed: 6 min read
- Last reviewed
- Legal status
- Leitweg-ID format specification 2.0.2 (version of 28 Jul 2021), federal e-invoicing ordinance (sections 3 to 5), BMF FAQ of 29 Oct 2026. Legal position as of 27 Nov 2026.
This article is general information and not legal or tax advice. For your individual case, please consult your tax adviser.
On this page
What the Leitweg-ID is
The Leitweg-ID is an identifier that lets invoices to public contracting authorities reach the right office automatically. The authority usually tells you the ID when it places the order. You enter it as the buyer reference (BT-10) in the XRechnung. If it is missing, the validator reports the error BR-DE-15, and an invoice receiving portal may reject the invoice.
Structure
A Leitweg-ID has up to three parts separated by hyphens: a coarse address, optionally a fine address, and a check digit pair. The worked example of the format specification reads:
04011000-1234512345-06| Part | Structure | Mandatory |
|---|---|---|
| Coarse address | 2 to 12 digits. The first two digits name the federal state (01 to 16) or the federal government (99). In the example, 04 stands for Bremen. | Yes |
| Fine address | Up to 30 characters from digits and the letters A to Z (upper or lower case makes no difference). The federal government and the states decide for themselves how it is used. | No |
| Check digits | Exactly 2 digits, calculated from the coarse and fine address without the hyphens under ISO/IEC 7064 (modulo 97-10). They detect syntax errors. | Yes |
The whole ID is 5 to 46 characters long, hyphens included. A checking tool can test the structure, the state code and the check digits. Whether the ID is actually assigned can only be confirmed by the contracting authority. The specification covers only the format; assigning IDs is up to the federal government and the states. We did not find a complete public directory. At federal level, the web entry of the invoice receiving portal keeps a directory of the connected Leitweg-IDs.
Where to get the Leitweg-ID
- The ID usually appears in the order, the contract or the tender documents. Look for the terms Leitweg-ID, buyer reference or invoice address.
- If you cannot find it there, ask the contracting authority or its invoice office.
- The ID belongs to the invoice recipient, not to you. You do not apply for it yourself.
- Use only the ID that the contracting authority names when it places the order. Do not copy IDs from online calculators or lists on the internet.
- An authority can have several IDs for different offices. Keep a list per customer and maintain it in your software, so that every invoice carries the right ID.
Entering the Leitweg-ID in the XRechnung
The Leitweg-ID goes into the field BT-10. In UBL the element is called BuyerReference; in CII it is also called BuyerReference, inside the trade agreement part (ApplicableHeaderTradeAgreement). In forms the field is usually called buyer reference, Leitweg-ID or customer reference. All that matters is that the value arrives in BT-10 of the file.
<!-- UBL --><cbc:BuyerReference>04011000-1234512345-06</cbc:BuyerReference><!-- CII --><ram:ApplicableHeaderTradeAgreement> <ram:BuyerReference>04011000-1234512345-06</ram:BuyerReference> <!-- … --></ram:ApplicableHeaderTradeAgreement>The federal invoice receiving portal (OZG-RE) accepts invoices by four routes: web entry, upload, Peppol and e-mail. Federal states and municipalities partly use other portals. Which route suits your authority is stated in its order documents. For Peppol, the Leitweg-ID scheme is registered as ICD 0204 and can serve as the participant identifier. The Peppol ID need not be identical to the Leitweg-ID, though; ask the authority.
How to check a Leitweg-ID
- Remove spaces and make sure only digits, letters and hyphens occur.
- Check the first two digits: they must be between 01 and 16 or be 99.
- Have the check digits recalculated. They catch most typing errors. The position of the hyphen does not enter the calculation, though; the specification therefore recommends starting the fine address with a letter.
- If in doubt, ask the contracting authority. Only it can confirm that the ID is assigned and belongs to this invoice.
This is how the specification calculates the check digits: join the coarse and fine address without hyphens, replace letters by their position in the alphabet (A = 10 to Z = 35), append two zeros, take the remainder of the division by 97 and subtract it from 98. In the example, 04011000123451234500 divided by 97 leaves a remainder of 92, and 98 − 92 gives the check digits 06. To verify, the whole number including the check digits is divided by 97; if the remainder is 1, the ID is formally valid.
The Leitweg-ID checker performs steps one to three in one go and shows which state code it recognised. A positive result means the ID is formally in order. It does not mean the authority will accept your invoice under this ID. That is the most common misconception.
Leitweg-ID between businesses
Between businesses you do not need a Leitweg-ID. XRechnung nevertheless requires a buyer reference. According to the BMF FAQ, a placeholder such as “-” is enough for VAT purposes. More useful is a value the recipient can match, for example the supplier number it has assigned to you. Whether it sets one is its own internal decision.
Rules for invoices to the federal government
- Invoice issuers must issue and transmit invoices to federal authorities electronically (section 3 (1) ERechV). Invoices after a direct order of up to EUR 1,000 are excluded (section 3 (3) no. 1 ERechV). The duty has applied since 27 November 2020.
- In principle, XRechnung in its current version is to be used. Another standard is permitted if it conforms to the European standard (section 4 (1) ERechV).
- Transmission runs through a federal administration portal, for which you register with a user account (section 4 (3) ERechV).
- Besides the VAT details, the invoice must contain at least the Leitweg-ID, the bank details, the payment terms and an e-mail or De-Mail address of the invoice issuer (section 5 (1) ERechV). Supplier number and order number are added if you received them when the order was placed (section 5 (2) ERechV).
- Other rules may apply to the federal states and municipalities. Ask the contracting authority. Where VAT law applies alongside the ERechV, the stricter rule governs.
Typical mistakes
| Mistake | Consequence | Remedy |
|---|---|---|
| Field BT-10 stays empty | The validator reports BR-DE-15; the portal may reject the invoice. | Enter the Leitweg-ID or, in B2B, a reference. |
| ID in the wrong field, such as the order number or free text | The invoice cannot be matched automatically. | Enter it in BT-10. |
| Typo or wrong check digits | The ID is invalid and the invoice does not arrive. | Copy the ID from the authority again and test it with a checking tool. |
| Spaces, line breaks or foreign hyphens in the ID | Validation and matching fail. | Write the ID without spaces and with plain hyphens. |
| Formally valid but unassigned or foreign ID | A checking tool cannot detect this; the invoice goes to the wrong office. | Have the authority confirm the ID. |
Automatic rejection
Under the federal e-invoicing ordinance, the federal administration portal automatically rejects formally faulty invoices. Check the file with a validator before you send it.
Frequently asked questions
Do I need a Leitweg-ID of my own?
No. The ID belongs to the invoice recipient. Enter the ID that the contracting authority gives you when it places the order.
Is the Leitweg-ID needed for invoices to businesses?
No. XRechnung does require a buyer reference, though. A placeholder is enough according to the BMF FAQ.
Sources
Every statement in this article rests on the texts below. Statutes and letters of the tax authorities can change; if in doubt, check the original wording.
- Leitweg-ID – format specification, version 2.0.2 (KoSIT, version of 28 Jul 2021) (opens in a new tab) – structure, state codes and check digits
- Federal E-Invoicing Ordinance (ERechV) (opens in a new tab) – sections 3 to 5: duty, data standard, mandatory content, rejection of formally faulty invoices
- E-invoicing at federal level: information for invoice issuers (opens in a new tab) – transmission routes to the federal government
- E-invoicing at federal level: frequently asked questions (opens in a new tab) – how to obtain the Leitweg-ID, directory in OZG-RE
- E-invoicing in the federal states (federal portal overview) (opens in a new tab) – federal states: contact points
- BMF FAQ “E-Rechnung” (as of 29 Oct 2026) (opens in a new tab) – question 6: Leitweg-ID in B2B
- KoSIT: XRechnung Schematron rules (releases) (opens in a new tab) – rule BR-DE-15
Try it now
Check a Leitweg-ID
Test the structure, state code and check digits of your Leitweg-ID.
Keep reading
- XRechnung or ZUGFeRD: Which Format for What?
XRechnung is a pure XML file, ZUGFeRD a PDF with embedded XML. Both can be valid e-invoices. Which one fits depends mostly on your recipient.
- Mandatory Details of an E-Invoice: Where Section 14 UStG Meets EN 16931
Section 14 UStG lists the mandatory tax details. EN 16931 and XRechnung require further fields. This article maps one onto the other.
- Checking E-Invoices: What Validators Check – and What They Do Not
A validator checks the structure and rules of an e-invoice, but not whether its content is true. This article explains the layers, the severities and the most frequent errors.