VAT Number Formats & Checksums: All 33 Countries

Every VAT or GST number a business hands you is a string that either matches a country's format or it does not. That format check, a regular expression plus sometimes a checksum digit, is the first and cheapest thing any validator can do: no network call, no upstream registry, just a pattern match against the digits the customer typed. It is also the most misunderstood part of VAT validation, because passing the regex is not the same thing as being a real, active registration.

This is the developer reference for that distinction across all 33 country prefixes Avatcado supports: the 27 EU member states, Northern Ireland (XI), the United Kingdom (GB) post-Brexit, Switzerland (CH) and Liechtenstein (LI), Norway (NO), and Australia (AU). Every pattern, local name, and checksum below is pulled directly from the same VAT_FORMAT_RULES table the Avatcado API itself validates against, so this table cannot silently drift out of sync with what the API actually accepts.

VAT number format reference: all 33 countries

"Checksum" below means the country embeds a check digit or check letter in the number itself, one that can be verified by arithmetic alone. Three formats in this table, Romania, Slovakia, and Sweden, have no checksum: any string of the right length and character set passes the format check, so a registry lookup is the only way to tell a real number from a made-up one.

CountryPrefixLocal nameFormatRegexChecksum
AustriaATUIDAT followed by the letter U and 8 digits/^U\d{8}$/Yes (Weighted MOD 10)
BelgiumBEbtw-nummerBE followed by 10 digits starting with 0 or 1/^[01]\d{9}$/Yes (MOD 97)
BulgariaBGDDS nomerBG followed by 9 or 10 digits/^\d{9,10}$/Yes (Weighted MOD 11 (UIC))
CroatiaHRPDV ID brojHR followed by 11 digits/^\d{11}$/Yes (ISO 7064 MOD 11,10)
CyprusCYFPACY followed by 8 digits and 1 letter/^\d{8}[A-Z]$/Yes (Check letter (MOD 26))
Czech RepublicCZDICCZ followed by 8, 9, or 10 digits/^\d{8,10}$/Yes (Weighted MOD 11 (ICO))
DenmarkDKmomsnummerDK followed by 8 digits/^\d{8}$/Yes (Weighted MOD 11)
EstoniaEEKMKR nrEE followed by 9 digits/^\d{9}$/Yes (Weighted MOD 10)
FinlandFIALV-numeroFI followed by 8 digits/^\d{8}$/Yes (Weighted MOD 11)
FranceFRnumero de TVAFR followed by a 2-character key and the 9-digit SIREN/^[A-Z0-9]{2}\d{9}$/Yes (MOD 97 key)
GermanyDEUSt-IdNr.DE followed by 9 digits/^\d{9}$/Yes (ISO 7064 MOD 11,10)
GreeceELAFMEL followed by 9 digits/^\d{9}$/Yes (MOD 11 (powers of 2))
HungaryHUadoszamHU followed by 8 digits/^\d{8}$/Yes (Weighted MOD 10)
IrelandIEVAT NoIE followed by 7 digits and 1 or 2 letters, or the older style of 1 digit, 1 letter, 5 digits, and 1 letter/^(\d{7}[A-Z]{1,2}|\d[A-Z]\d{5}[A-Z])$/Yes (MOD 23 letter check)
ItalyITP.IVAIT followed by 11 digits/^\d{11}$/Yes (Luhn MOD 10)
LatviaLVPVN numursLV followed by 11 digits/^\d{11}$/Yes (Weighted MOD 11)
LithuaniaLTPVM kodasLT followed by 9 or 12 digits/^\d{9}(\d{3})?$/Yes (Weighted MOD 11)
LuxembourgLUno TVALU followed by 8 digits/^\d{8}$/Yes (MOD 89)
MaltaMTVAT NoMT followed by 8 digits/^\d{8}$/Yes (Weighted MOD 37)
NetherlandsNLbtw-idNL followed by 9 digits, the letter B, and 2 digits/^\d{9}B\d{2}$/Yes (11-proef / MOD 97)
PolandPLNIPPL followed by 10 digits/^\d{10}$/Yes (Weighted MOD 11)
PortugalPTNIFPT followed by 9 digits/^\d{9}$/Yes (MOD 11)
RomaniaROTVARO followed by 2 to 10 digits/^\d{2,10}$/No
SlovakiaSKIC DPHSK followed by 10 digits/^\d{10}$/No
SloveniaSIID za DDVSI followed by 8 digits/^\d{8}$/Yes (MOD 11)
SpainESNIF-IVAES followed by 9 characters: a letter or digit, then 7 digits, then a letter or digit/^[A-Z0-9]\d{7}[A-Z0-9]$/Yes (Control character)
SwedenSEmomsnummerSE followed by 12 digits/^\d{12}$/No
Northern IrelandXIVAT Reg NoXI followed by 9 or 12 digits/^\d{9}(\d{3})?$/Yes (MOD 97 / MOD 9755)
United KingdomGBVRNGB followed by 9 or 12 digits/^\d{9}(\d{3})?$/Yes (MOD 97 / MOD 9755)
SwitzerlandCHMWST-Nr.CHE followed by 9 digits and an MWST, TVA, or IVA suffix/^\d{9}$/Yes (MOD 11)
LiechtensteinLIMWST-Nr.CHE followed by 9 digits with an MWST suffix, identical to the Swiss scheme (LI + 9 digits is also accepted)/^\d{9}$/Yes (MOD 11)
NorwayNOMVA-nummerNO followed by 9 digits with an MVA suffix/^\d{9}$/Yes (MOD 11)
AustraliaAUABNAU followed by 11 digits (the ABN)/^\d{11}$/Yes (MOD 89)

Every row links to that country's own page, which adds the check-digit description in full, a real registered example number, and a free live checker against the actual registry.

How the checksums work: three worked examples

Most checksums in the table above follow the same shape: multiply each digit by a fixed weight, sum the results, and take the sum modulo some base. The base and weights differ per country, but three of Avatcado's own checksum functions (all MOD 11 or MOD 89 style, and all documented above) are simple enough to walk through by hand.

Switzerland (CH): weighted MOD 11

A Swiss UID like CHE-105.836.495 validates as CH105836495. Drop the CH prefix and MWST suffix to get nine digits: 105836495. Multiply the first eight, 1, 0, 5, 8, 3, 6, 4, 9, by the weights 5, 4, 3, 2, 7, 6, 5, 4: that gives 5 + 0 + 15 + 16 + 21 + 36 + 20 + 36 = 149. Take 149 mod 11 = 6, then 11 - 6 = 5. That is the ninth digit of the real number, so it checks out.

Norway (NO): weighted MOD 11

A Norwegian organization number, NO982463718MVA, strips down to 982463718. The first eight digits, 9, 8, 2, 4, 6, 3, 7, 1, are weighted 3, 2, 7, 6, 5, 4, 3, 2: 27 + 16 + 14 + 24 + 30 + 12 + 21 + 2 = 146. 146 mod 11 = 3, and 11 - 3 = 8, matching the real ninth digit. Same mechanism as Switzerland, different weights.

Australia (AU): weighted MOD 89

The Australian ABN checksum works the same way with a different base and an extra first step. For AU51824753556, subtract 1 from the first digit only (5 becomes 4), then weight all eleven digits 10, 1, 3, 5, 7, 9, 11, 13, 15, 17, 19: 40 + 1 + 24 + 10 + 28 + 63 + 55 + 39 + 75 + 85 + 114 = 534. A valid ABN divides evenly by 89, and 534 / 89 = 6 exactly.

A remainder-based check like these three catches typos and transposed digits before they ever reach a network call, but it cannot tell you whether a number was ever issued. A string that happens to satisfy the arithmetic is exactly as "checksum-valid" as one that a real tax authority assigned to a real business.

Edge cases the regex alone cannot capture

Format documentation in this reference comes with notes for exactly this reason: some countries have quirks that a plain pattern match will not surface on its own.

Northern Ireland's XI prefix

Same digits as the trader's GB VAT number with XI substituted for GB; it is an add-on to the UK VAT registration, not a separate one XI numbers validate in VIES; GB numbers were removed from VIES on 1 January 2021 A validator that only recognizes GB and the 27 EU prefixes will reject every Northern Ireland goods registration; XI needs to be its own supported prefix, not folded into GB.

Greece: EL, not GR

The prefix is EL (from Ellada/Hellas), not the ISO code GR; GR-prefixed numbers fail VIES

The United Kingdom, post-Brexit

GB numbers are not in VIES since 1 January 2021; validate via HMRC's checker or the Check a UK VAT Number API

See the HMRC VAT Check API guide for what replaced VIES coverage for GB numbers.

Format-valid is not the same as registered

Nothing on this page, or in the VAT_FORMAT_RULES table it is generated from, can tell you whether a number was ever issued to a real business, or whether that business is still active. Format checking rules out obvious typos and malformed input before you spend a network round trip on it. Confirming the number is real is a separate step, one that has to go to the actual registry: VIES for the EU and Northern Ireland, HMRC for the UK, the BFS UID Register for Switzerland and Liechtenstein, the Bronnoysund Register for Norway, and the ABR for Australia. Each of those is a different service with its own uptime, rate limits, and response shape, which is the whole reason to put one API in front of all of them rather than integrating each registry separately.

Avatcado's free VAT checker runs both steps for any of the 33 formats above: format validation first, then a live registry lookup, with no account required. For the same logic wired into your own backend, the how to validate EU VAT numbers programmatically guide covers the REST API end to end, and validating VAT numbers in TypeScript covers the same flow with the typed SDK.

Get started

Avatcado's free tier includes 500 registry validations per month, on top of unlimited local format checking. No credit card required.

Start validating for free →

Frequently asked questions

Does a VAT number that matches the format regex mean it is registered and active?

No. The format regex only confirms the string has the right shape: prefix, length, character classes, and (where the country has one) a checksum digit that satisfies the arithmetic. It says nothing about whether that number was ever issued to a real business or whether the registration is still active. A string that happens to satisfy a MOD 11 checksum is exactly as 'checksum-valid' as one a real tax authority assigned. Treat format checking as a cheap pre-filter: it runs locally with no network call and catches typos, transposed digits, and malformed input before you spend a registry lookup on them. Confirming registration is the separate, authoritative step, and it has to go to the actual registry: VIES for the EU and Northern Ireland, HMRC for the UK, the BFS UID Register for Switzerland and Liechtenstein, the Bronnoysund Register for Norway, and the ABR for Australia. Avatcado runs both steps on every validation.

Which of the 33 supported VAT number formats include a checksum digit?

30 of the 33 do. Romania, Slovakia, and Sweden are the exceptions: their formats embed no check digit, so any string of the right length and character set passes format validation, and a registry lookup is the only way to distinguish a real number from a made-up one. For the 30 formats that do carry a checksum, most follow the same basic shape: multiply each digit by a fixed per-country weight, sum the products, and take the sum modulo some base. Switzerland and Norway both use weighted MOD 11 with different weight sequences, and Australia's ABN uses a weighted MOD 89 check with an extra first step (subtract 1 from the first digit before weighting). A checksum catches typos and transposed digits locally, before any network call, but even a checksum-valid number can be unissued or deactivated, so the checksum column tells you how much a format check can rule out, never whether a number is real.

Why do some EU country prefixes not match the ISO country code?

Greece uses EL (from Ellada/Hellas) instead of its ISO code GR, and GR-prefixed numbers fail VIES entirely, so if your form derives the VAT prefix from an ISO country selection you need a special case that maps Greece to EL before validating. Northern Ireland uses XI, which is not an ISO country code at all but an EU-assigned prefix for the post-Brexit Windsor Framework arrangement covering goods trade: Northern Ireland businesses trading goods under that arrangement validate through VIES with the XI prefix, while GB numbers left VIES at Brexit and validate through HMRC instead. A validator that only recognizes GB plus the 27 EU prefixes will therefore reject every Northern Ireland goods registration; XI has to be its own supported prefix, not folded into GB. These two prefixes are the classic pitfalls when deriving a VAT prefix from a customer's billing country, so handle them explicitly rather than assuming the prefix always equals the ISO code.

How does a MOD 11 checksum like Switzerland's or Norway's actually work?

Each digit before the last is multiplied by a fixed weight, the products are summed, and the sum is taken modulo 11. If the remainder is 0, the check digit is 0; otherwise the check digit is 11 minus the remainder. A worked Swiss example: CHE-105.836.495 strips to 105836495, and the first eight digits weighted 5, 4, 3, 2, 7, 6, 5, 4 sum to 149. Then 149 mod 11 is 6, and 11 minus 6 is 5, which matches the real ninth digit. Norway uses the identical mechanism over the nine-digit organization number with the weight sequence 3, 2, 7, 6, 5, 4, 3, 2, so the same worked-example method applies to both; only the weights differ. Australia's ABN check is a close cousin: subtract 1 from the first digit, weight all eleven digits, and require the sum to divide evenly by 89. All of these catch typos locally but prove nothing about actual registration.

Sources

Try it on a real VAT number

Check any VAT or GST number against the official registry for free, no account needed.

Related guides