Quaterio
EN 16931 error reference

Total and arithmetic rules

The numbers on the invoice do not add up. 23 rules.

The BR-CO family checks that the invoice is internally consistent: that the totals equal the sum of what they claim to total. BR-CO-15, the one everybody meets first, says the gross total must equal the net total plus the VAT total.

The overwhelming cause is rounding that accumulates. Calculate VAT per line, round each one to two decimals, sum them, and the result sits a cent away from VAT calculated on the invoice total. Both are defensible arithmetic and only one of them satisfies the rule.

Derive every total from the lines in one place rather than calculating the same figure twice by different routes. Underneath, amounts should be fixed scale decimals from end to end, because a JSON number is how 1234.5000000001 reaches an invoice.

BR-CO-03
BT-7 and BT-8 are two ways of saying when VAT became chargeable, and only one may be present. Remove whichever your system did not mean to send: BT-7 is an actual date, BT-8 is a code such as "delivery date".
BR-CO-04
Every invoice line needs a VAT category code (BT-151), including lines at zero rate or exempt. A line with no category cannot be assigned to any VAT breakdown, which is why this usually fails alongside BR-CO-18.
BR-CO-05
A document level allowance carries both a reason code (BT-98) and a reason text (BT-97), and they must describe the same thing. This trips when the code is set from a fixed list while the text is free-typed, so pick the text to match the code rather than the other way round.
BR-CO-06
Same as BR-CO-05 but for a document level charge: the reason code (BT-105) and reason text (BT-104) must agree.
BR-CO-07
An invoice line allowance has a reason code (BT-140) and reason text (BT-139) that must describe the same type of allowance.
BR-CO-08
An invoice line charge has a reason code (BT-145) and reason text (BT-144) that must describe the same type of charge.
BR-CO-09
VAT identifiers must start with the two-letter ISO 3166-1 country code of the country that issued them, for example FR12345678901 or DE123456789. A bare number fails this, as does a VAT number with the country in a separate field. Note Greece uses EL, not GR.
BR-CO-10
The sum of line net amounts (BT-106) does not equal the sum of the individual line amounts (BT-131). Recalculate the total from the lines rather than carrying it over from another system, and check that line level allowances and charges are reflected in each line net amount.
BR-CO-11
The sum of document level allowances (BT-107) does not equal the sum of the individual allowance amounts (BT-92). Recalculate it from the allowances present rather than copying a discount total from elsewhere.
BR-CO-12
The sum of document level charges (BT-108) does not equal the sum of the individual charge amounts (BT-99). Recalculate from the charges present.
BR-CO-13
The invoice total without VAT (BT-109) must equal the sum of line net amounts (BT-106), minus document level allowances (BT-107), plus document level charges (BT-108). A mismatch here is almost always a discount or surcharge applied in one place but not the other, or a line level allowance double counted at document level.
BR-CO-14
The invoice total VAT amount (BT-110) must equal the sum of the VAT amounts in each breakdown (BT-117). Sum the categories rather than recomputing VAT on the invoice total, which rounds differently when more than one rate is present.
BR-CO-15
The invoice total with VAT (BT-112) must equal the total without VAT (BT-109) plus the total VAT (BT-110). This is the single most common EN 16931 failure, and it is usually rounding: round each VAT category once, then sum, rather than summing then rounding.
BR-CO-16
The amount due for payment (BT-115) must equal the total with VAT (BT-112), minus any amount already paid (BT-113), plus any rounding amount (BT-114). If nothing has been paid, BT-113 should be absent or zero rather than omitted from the calculation.
BR-CO-17
The VAT amount for a category (BT-117) must equal its taxable amount (BT-116) multiplied by the rate (BT-119) divided by 100, rounded to two decimals. Note the rate is a percentage: 20 means 20%, not 0.20. Round once here, at the category level.
BR-CO-18
An invoice needs at least one VAT breakdown group (BG-23), even when no VAT is charged. An exempt or reverse charge invoice still needs a breakdown stating that, with the category code and the reason.
BR-CO-19
An invoicing period (BG-14) was opened but neither the start date (BT-73) nor the end date (BT-74) was filled. Supply at least one, or remove the period entirely.
BR-CO-20
An invoice line period (BG-26) was opened but neither the start date (BT-134) nor the end date (BT-135) was filled. Supply at least one, or remove the period from the line.
BR-CO-21
Each document level allowance (BG-20) needs a reason text (BT-97) or a reason code (BT-98). An unexplained discount cannot be checked by the recipient, so the standard requires one or the other.
BR-CO-22
Each document level charge (BG-21) needs a reason text (BT-104) or a reason code (BT-105).
BR-CO-23
Each invoice line allowance (BG-27) needs a reason text (BT-139) or a reason code (BT-140).
BR-CO-24
Each invoice line charge (BG-28) needs a reason text (BT-144) or a reason code (BT-145).
BR-CO-26
The buyer has no way to identify you automatically. Supply at least one of the seller identifier (BT-29), the seller legal registration identifier (BT-30) or the seller VAT identifier (BT-31). A name and address alone is not machine-matchable against a supplier record.

Check your own invoice

Drop a Factur-X or ZUGFeRD file into the free validator and it names every rule that fails, with the explanation from this page attached to each one. The EN 16931 rules run in your browser, so the invoice is never uploaded. The ISO PDF/A-3, XRechnung and PEPPOL BIS checks need a server and are a separate opt in that says so.

Validate an invoice, no signup

The other rule families