# HR-BR-53

Source: https://xmlvalid.com/rules/HR-BR-53

> HR PDV identifikacijski broj (BT-31, BT-48, BT-63) ili porezni identifikator (BT-32) mora biti ispravan OIB

- Level: error
- Rule sets: Croatian eRačun rules (UBL) 13.03.2026
- Context: `cac:AccountingSupplierParty/cac:Party/cac:PartyTaxScheme`
- Test: `(u:ctrlOIB(cbc:CompanyID)) or (../cac:PostalAddress/cac:Country/cbc:IdentificationCode != 'HR')`

> HR PDV identifikacijski broj (BT-31, BT-48, BT-63) ili porezni identifikator (BT-32) mora biti ispravan OIB

- Level: error
- Rule sets: Croatian eRačun rules (UBL) 13.03.2026
- Context: `cac:AccountingCustomerParty/cac:Party/cac:PartyTaxScheme`
- Test: `(u:ctrlOIB(cbc:CompanyID)) or (../cac:PostalAddress/cac:Country/cbc:IdentificationCode != 'HR')`

> HR PDV identifikacijski broj (BT-31, BT-48, BT-63) ili porezni identifikator (BT-32) mora biti ispravan OIB

- Level: error
- Rule sets: Croatian eRačun rules (UBL) 13.03.2026
- Context: `cac:TaxRepresentativeParty/cac:PartyTaxScheme`
- Test: `(u:ctrlOIB(cbc:CompanyID)) or (../cac:PostalAddress/cac:Country/cbc:IdentificationCode != 'HR')`

In English: A Croatian VAT identifier (BT-31, BT-48, BT-63) or tax registration identifier (BT-32) must be a valid OIB.

## Why it fails

- The seller's, buyer's or tax representative's `cac:PartyTaxScheme/cbc:CompanyID` is not a valid OIB, while the party's country (`cac:PostalAddress/cac:Country/cbc:IdentificationCode`) is HR.
- The identifier has the `HR` prefix and a check digit error, or extra spaces; the check digit (ISO 7064, MOD 11,10) is recalculated.

## How to fix it

- Give the party's eleven digit OIB, with or without the `HR` prefix, and check it against the register. A party outside Croatia keeps its own VAT number and its own country code.

Validate a document against these rules: https://xmlvalid.com/validate
