EU VAT number check with VIES in B2B and reverse charge
The module for this problem
B2B VAT - VIES validation & intra-EU reverse charge
Checks EU VAT numbers on VIES at registration, when an address is saved and at checkout, and applies the intra-EU exemption to customers with a valid number from another country. If VIES does not respond, the customer is not blocked. PrestaShop 1.7.7, 8 and 9, 12 months of updates included, then optional renewal.
Why the customer’s VAT number must be checked in B2B
When an online shop sells to a business in another EU country, VAT follows different rules from a sale to a consumer, and they differ again between goods and services. The starting point is common: the customer must be a taxable person with a VAT identification number and the shop must be able to prove it.
This page summarises the practical points on the basis of the official texts listed at the bottom. It is orientation, not tax advice: national transposition, special schemes and your specific case must be checked with your accountant.
Goods and services: two different mechanisms
| Supply of goods | Supply of services | |
|---|---|---|
| Basic rule | Exemption for goods dispatched or transported to another Member State (Directive 2006/112/EC, Article 138(1)) | Place of supply in the customer’s State (Article 44) and VAT payable by the customer when the supplier is not established in that State (Article 196) |
| Who accounts for the VAT | The purchaser, on the intra-Community acquisition in their State (Articles 2 and 40) | The customer, through the reverse charge (Article 196) |
| Condition on the customer | Is identified for VAT in a State other than the one of departure and has communicated the number to the supplier (Article 138(1)(b)) | Unless there is information to the contrary, the supplier may regard them as a taxable person if the supplier has their number and obtains confirmation through VIES (Implementing Regulation 282/2011, Article 18) |
| On the invoice | Customer’s VAT number and reference to the exemption (Article 226, points (4) and (11)) | Customer’s VAT number and the mention “Reverse charge” (Article 226, points (4) and (11a)) |
What the reverse charge is
With the reverse charge, it is the customer, not the person providing the service, who must pay the VAT: Article 196 provides that the tax is payable by the taxable person to whom a service referred to in Article 44 is supplied, if the service is supplied by a taxable person not established in that Member State. On the invoice the supplier declares it with the mention “Reverse charge” (Article 226, point (11a)). For goods the logic is related but different: the supply is exempt and the purchaser accounts for the VAT on the intra-Community acquisition, which is deemed to take place where the goods arrive (Articles 2 and 40).
Goods: communicated number and recapitulative statement
Since 1 January 2020, Article 138 is the one rewritten by Directive (EU) 2018/1910: besides the VAT number communicated by the purchaser, paragraph 1a provides that the exemption does not apply if the supplier has not submitted the recapitulative statement required by Articles 262 and 263, or if the statement does not set out correct information on the supply, unless the supplier can give a justification that the authorities consider satisfactory. The VIES FAQ also reminds that the customer’s number shown in the recapitulative statement must be correct.
How VIES works and what it answers
VIES is an electronic tool for validating the VAT numbers of operators registered in the EU. There is no central database: the request is sent to the national database of the State that issued the number, and the answer is only as good as that State’s data. Regulation (EU) No 904/2010 (Article 31) provides for electronic confirmation of the validity of the number and, in accordance with each State’s data protection rules, of the name and address.
The VIES help page lists the possible answers:
- Valid number.
- Invalid number, that is, not valid at least on the date shown.
- Service unavailable: problems with the network or the web application.
- Member State service unavailable: the application of the State that issued the number cannot be reached.
- Incomplete or incorrect data.
- Request timed out.
In the technical documentation the same situations appear as codes: MS_UNAVAILABLE (Member State application not available), SERVICE_UNAVAILABLE (network or application error) and TIMEOUT (no reply within the time allowed).
What “invalid” means
The official FAQ first advises checking that the number is written correctly (characters, length, country prefix). It adds that some States require a further registration for intra-Community transactions: a correct number may therefore not appear as valid on VIES because the holder does not carry out those transactions or is not registered for them. The customer can ask their own tax administration to update the data: the FAQ reminds that only the national administrations can do so.
Name and address do not always arrive
For a valid number, if the name or address is replaced by “---” the State that issued the number does not authorise its disclosure. For Spain the FAQ explains that name, address and type of company must be entered together with the number, because the Spanish database does not supply them on its own.
The consultation number
If you enter your own VAT number as the requester, the answer contains a unique consultation number. The help page advises keeping it if you want to be able to prove to a tax administration that the check was made at a given time. The same text specifies that confirmation of validity is only one of the elements of proof supporting the exemption (Article 138(1)), and the service disclaimer repeats that the information does not in itself give the right to exempt. VIES also confirms validity only for the current date, not for past periods.
If VIES does not respond
The FAQ admits that some parts of the system may be inaccessible at certain times (database backups) and the help page publishes the maintenance windows of the individual States. The technical information also mentions a status service (check-status) on the availability of the national services.
The basic rule is not to confuse “unavailable” with “invalid”: they are different answers. Treating them in the same way leads to two opposite errors, turning away a customer who is in order or granting the exemption without a confirmation. On this point the FAQ says only one thing: if you believe the customer is not a taxable person, you must not exempt the supply but charge VAT. The rest is a choice to agree with your accountant. The options most often encountered are:
- repeat the check later, noting the date, time, number and result of each attempt;
- do not grant the exemption until a confirmation arrives, and correct afterwards if needed;
- grant the exemption and carry out the check before issuing the invoice.
None of them is a guarantee.
If the number is not valid
In general the exemption is not granted. For goods the condition of Article 138 is that the purchaser is identified and has communicated the number; for electronic services the VIES FAQ states that, if the customer does not have a valid number, the supplier must charge VAT. If the customer is a consumer, other rules apply: since 1 July 2021 there is a single threshold of 10,000 euros for intra-EU distance sales (Article 59c, introduced by Directive (EU) 2017/2455) and the OSS scheme allows the VAT due in other States to be declared from a single Member State.
Checklist for a B2B shop
- The VAT number field accepts the country prefix, with the codes used by VIES (for example EL for Greece and XI for Northern Ireland).
- The number is checked on VIES at a precise moment (registration, address, checkout) and the result stays recorded with date and time.
- The exemption is applied only with a valid number from another State, consistent with the country of the address.
- The process distinguishes “invalid” from “not verifiable” and has a written rule for the second case.
- Where proof is needed, the consultation number obtained by entering your own VAT number is kept.
- The invoice shows the customer’s VAT number and the reference to the exemption or the mention “Reverse charge” (Article 226).
- The recapitulative statement is submitted and shows the right numbers (Articles 262 and 263).
- Recurring customers are rechecked from time to time, because VIES confirms only today’s situation.
How the B2B VAT - VIES validation & intra-EU reverse charge module does it
- Checks the number on VIES at registration, when an address is saved and at checkout (three separate switches) and, before the call, verifies that the format is plausible for the country.
- Queries the VIES REST service and, if it does not respond, the SOAP one. An outage or an unavailable State is recorded as “not verifiable”, never as “invalid”, and the customer is not blocked.
- Applies the exemption only if the number is valid, from an EU country other than the shop’s and consistent with the country of the address. With the name option on, it requires the name returned by VIES to match the customer’s; if VIES returns no name, the exemption is denied.
- Assigns eligible customers to a B2B group and sets the VAT on products and shipping to zero for eligible addresses. To avoid slowing down the cart it does so based on the last stored result, without querying VIES at every calculation.
- Keeps a history with one row per number (status, name returned, source, date), a 30-day cache that can be changed, manual revalidation and the forcing of a result.
- If VIES does not respond, it lets the customer proceed silently or with a notice, as you choose. The option that blocks invalid numbers is off by default.
See the module page or read the installation and setup guide.
Official sources
- Directive 2006/112/EC, consolidated text (EUR-Lex): Articles 2, 40, 44, 59c, 138, 196, 226, 262 and 263
- Directive (EU) 2018/1910, applicable from 1 January 2020 (EUR-Lex)
- Implementing Regulation (EU) No 282/2011, Article 18 (EUR-Lex)
- Regulation (EU) No 904/2010, Article 31 (EUR-Lex)
- Directive (EU) 2017/2455 (EUR-Lex)
- European Commission, VIES: help, FAQ, technical information, disclaimer
- European Commission, VAT One Stop Shop portal
Frequently asked questions
What should a shop check before applying the exemption to an EU customer?
That the customer is a taxable person with a VAT number from another Member State and has communicated it. For services, Implementing Regulation 282/2011 (Article 18) allows the supplier to regard the customer as such if confirmation is obtained through VIES; for goods, the conditions of Article 138 also apply, including the recapitulative statement.
What is the difference between “invalid” and “service unavailable”?
“Invalid” concerns the number: it is not valid, at least on the date shown. “Service unavailable” means that the check was not carried out because of a problem with the network, the application or the State that issued the number. They are different answers and should not be treated in the same way.
What is the consultation number for?
VIES returns it when you enter your own VAT number as the requester and advises keeping it as proof of the check. It is not the only proof: confirmation of validity is just one of the elements supporting the exemption.
Does VIES always return the name and address?
No. If “---” appears for a valid number, the State that issued it does not authorise its disclosure. For Spain, the FAQ explains that the name and address must be provided together with the number.
What should be done if VIES does not respond?
Tell the outage apart from an invalid number, repeat the check later and note the attempts. Whether it is acceptable to grant the exemption anyway and verify before the invoice is for your accountant to decide.
Is the module enough on its own?
No. The module automates the check, records the result and applies the exemption only to eligible customers, but it does not replace tax assessments. It neither requests nor stores the consultation number, does not write the legal mentions on the invoice, does not submit the recapitulative statement, does not verify proof of transport and does not distinguish between goods and services: these steps remain with you and your accountant.
