How do I validate my XRechnung before sending it?

In short: The authoritative result is the report of the official KoSIT validator with the current XRechnung validation configuration. Many invoice receiving platforms use the same combination. Check your files with it before you send them.

What you need

The validation configuration is updated regularly. Always use the latest version – rules can change, as most recently with CII-SR-465 (German).

Running the validation

java -jar validator-standalone.jar -s configuration\scenarios.xml -r configuration -o report invoice.xml

-s points to the scenarios.xml file of the unpacked configuration, -r to its folder, -o to the output folder for the report. The validator checks XRechnungen in both syntaxes (CII and UBL).

Reading the result

The console shows ACCEPTABLE or REJECT. The report folder contains the detailed report with all messages and their location in the file. Errors lead to rejection, warnings do not.

Common errors

And the SDK's schema check?

ValidateXmlAgainstXsd of the Aloaha ZUGFeRD SDK checks a file against an XSD schema, i.e. only the structure. The business rules (calculation rules, mandatory fields, BR-DE rules) are only checked by the KoSIT validator.

Frequently asked questions

Which validator is authoritative for the XRechnung?

The official KoSIT validator with the current XRechnung validation configuration. Many invoice receiving platforms use the same combination.

Do warnings lead to rejection?

No. Only errors lead to REJECT; warnings appear in the report but the invoice is still ACCEPTABLE.

Is the XSD schema check of the SDK enough?

No. ValidateXmlAgainstXsd only checks the structure against the schema. Calculation rules, mandatory fields and the German BR-DE rules are only checked by the KoSIT validator.