Key points
- Every Peppol invoice line needs a unit code (BR-23) from UN/ECE Recommendation 20, with the Rec 21 packaging extension (BR-CL-23).
- Codes are case sensitive: HUR passes, hur fails. Common ERP codes such as PCE, HRS, KG and BOX are not valid.
- Some invalid-looking codes pass but mean something else: KGS is kilogram per second and PAL is pascal. A pallet is XPX.
- UK and US imperial units have separate codes: GLI gallon (UK) vs GLL gallon (US), PTI pint (UK) vs PTL liquid pint (US).
- A price base quantity must use the same unit as the invoiced quantity (PEPPOL-EN16931-R130) and be above zero (R121).
Every line in a Peppol invoice must say what unit its quantity is in, using a code from UN/ECE Recommendation 20 (with the Recommendation 21 packaging codes). The most common UK choices are C62 for one unit or item, HUR for hours, KGM for kilograms and LTR for litres. ERP abbreviations such as PCE, HRS or KG fail, and a few look-alikes pass but mean something else entirely.
The rules
| Rule | Text | Severity |
|---|---|---|
| BR-23 | "An Invoice line (BG-25) shall have an Invoiced quantity unit of measure code (BT-130)." | Fatal |
| BR-CL-23 | "Unit code MUST be coded according to the UN/ECE Recommendation 20 with Rec 21 extension" | Fatal |
| PEPPOL-EN16931-R130 | "Unit code of price base quantity MUST be same as invoiced quantity." | Fatal |
| PEPPOL-EN16931-R121 | "Base quantity MUST be a positive number above zero." | Fatal |
| UBL-CR-663 | "A UBL invoice should not include the unitCodeListID" | Warning |
BR-CL-23 applies to cbc:InvoicedQuantity, cbc:CreditedQuantity and cac:Price/cbc:BaseQuantity. The Peppol code list page shows Revision 11e; the current validation artefact accepts 2,162 codes. The comparison is exact, so codes are case sensitive.
<cbc:InvoicedQuantity unitCode="HUR">7.5</cbc:InvoicedQuantity>
Codes UK businesses use most
Names as given in the Peppol code list:
| Use | Code | Name |
|---|---|---|
| Single items | C62 | one |
| EA | each | |
| H87 | piece | |
| NAR | number of articles | |
| SET | set | |
| PR | pair | |
| DZN | dozen | |
| Time | HUR | hour |
| MIN | minute [unit of time] | |
| DAY | day | |
| WEE | week | |
| MON | month | |
| ANN | year | |
| Services | E48 | service unit |
| LS | lump sum | |
| Weight | KGM | kilogram |
| GRM | gram | |
| TNE | tonne (metric ton) | |
| Volume | LTR | litre |
| MLT | millilitre | |
| MTQ | cubic metre | |
| Length and area | MTR | metre |
| KMT | kilometre | |
| MTK | square metre | |
| Energy | KWH | kilowatt hour |
| MWH | megawatt hour (1000 kW.h) | |
| Packaging (Rec 21) | XBX | Box |
| XCT | Carton | |
| XPK | Package | |
| XPX | Pallet | |
| XPP | Piece |
UK imperial units and the US look-alikes
| UK unit | Code | Do not confuse with |
|---|---|---|
| Gallon | GLI gallon (UK) | GLL gallon (US) |
| Pint | PTI pint (UK) | PTL liquid pint (US) |
| Long ton (2,240 lb) | LTN ton (UK) or long ton (US) | STN ton (US) or short ton (UK/US) |
| Pound | LBR pound | |
| Ounce | ONZ ounce (avoirdupois) | |
| Foot, inch, yard | FOT, INH, YRD | |
| Mile | SMI mile (statute mile) | |
| Acre | ACR acre |
A UK gallon is larger than a US gallon, so a fuel or chemicals invoice coded GLL instead of GLI states a different quantity even though it passes validation.
Codes that fail, and codes that pass but are wrong
We checked common ERP abbreviations against the 3.0.21 list and ran several through the full rules:
| Sent | Result | Use instead |
|---|---|---|
PCE, PCS, NOS, UNT |
Not in list (BR-CL-23) | C62, H87 or EA |
HRS, HR |
Not in list (BR-CL-23) | HUR |
hur |
BR-CL-23 (case) | HUR |
KG |
Not in list | KGM |
M |
Not in list | MTR |
GAL |
Not in list | GLI |
BOX, PK |
Not in list | XBX, XPK |
| No unitCode | BR-23 | Any valid code |
KGS |
Passes, but means "kilogram per second" | KGM |
PAL |
Passes, but means "pascal" | XPX (Pallet) |
MTS |
Passes, but means "metre per second" | MTR |
The last three are the dangerous ones: the invoice validates, and the receiver's system may read nonsense units. Map codes explicitly; do not let an ERP's "units" field flow straight into unitCode.
Price per 100 or per 1,000: base quantity
If you price per 1,000 units, use cbc:BaseQuantity. Its unit must match the invoiced quantity (R130), and it must be above zero (R121):
<cbc:InvoicedQuantity unitCode="C62">1000</cbc:InvoicedQuantity>
<cbc:LineExtensionAmount currencyID="GBP">130.00</cbc:LineExtensionAmount>
<!-- ... -->
<cac:Price>
<cbc:PriceAmount currencyID="GBP">130.00</cbc:PriceAmount>
<cbc:BaseQuantity unitCode="C62">1000</cbc:BaseQuantity>
</cac:Price>
Changing the base quantity unit to H87 failed R130. A base quantity of 0 failed R121 and also R120, the line amount check. Adding unitCodeListID gave warning UBL-CR-663.
The HMRC side
VAT Notice 700, 16.3.1 requires "for each description, the quantity of the goods or the extent of the services". 16.3.2 says the unit price requirement "applies to countable goods or services", such as "an hourly rate". The unit code is how a structured invoice says what the quantity counts. HMRC does not prescribe Rec 20 codes; that comes from EN 16931 and Peppol.
Not yet settled for the UK
There is no UK e-invoice specification yet. Whether it will restrict or recommend particular unit codes is not yet confirmed. Some sectors (for example NHS supply chain or construction) may agree conventions with their suppliers; check buyer onboarding guides.
What to do now
- Export the distinct units your ERP uses and map each one to a Rec 20 code.
- Check for KGS, PAL, MTS and GLL in that mapping.
- Use C62 for generic items unless a customer asks otherwise.
- Test with a Peppol validator.
Related: common Peppol validation errors, master data clean-up.
Frequently asked questions
What unit code should I use for 'each' in Peppol?
C62 (one) is the most widely used code for a unit or item. EA (each) and H87 (piece) are also valid Rec 20 codes. Agree one with your main customers and use it consistently.
What is the Peppol unit code for hours?
HUR. Codes like HRS or HR fail BR-CL-23. Minutes are MIN, days DAY, weeks WEE, months MON and years ANN.
What is the code for a UK gallon?
GLI is gallon (UK). GLL is gallon (US), a smaller unit. For pints, PTI is pint (UK) and PTL is liquid pint (US).
Why does my invoice fail BR-CL-23?
The unitCode attribute is not in the UN/ECE Rec 20 list (with Rec 21 X codes). Typical causes are ERP abbreviations such as PCE, KG, HRS or BOX, and lower case.
Spotted a mistake? Report an error. einvoices.uk is an independent publication and is not affiliated with HMRC. Details of the mandate may change; check the sources and official GOV.UK guidance before acting.