VAT Validation

VAT Validation, is a means to validate an EU customers VAT number to ensure the tax rules are appropriately applied. You may want to set this up in the instance that you trade with both Retail and Trade EU customers (both EU-registered business entities) and you want Magento to intelligently distinguish between the two for tax purposes.

VAT validation can be configured to occur from within the customers account (both front and backend) and at checkout (both front and backend).

NoteVAT should be charged is the merchant and the customer are in the same country regardless of whether VAT validation is successful.

Since there are quite a few variables involved in setting this up, I think the best first step in the process is to have a look at the flow of events so that you are aware of all the pieces involved and can then start understanding how everything will need to be laid out for them to fit together.



Above is the VAT validation configuration screen. Some of the fields are confusingly labelled and defined, so I am going to try and do one better.

Enable Automatic Assignment to Customer Group - 

Tax Calculation Based On - The options here are either Billing Address or Shipping Address. Typically this is set to Shipping Address, as you want the customer to pay the applicable tax rules of where they are receiving the goods (not necessarily the tax rules of where their credit cards are registered).

Default Group -  This is customer group that you want ALL customers to default into (regardless of whether VAT is valid or invalid).

Group for Valid VAT ID - Domestic - This is the customer group that will be assigned to customers with valid VAT IDs that are from the same country as you.

Group for Valid VAT ID - Intra-Union - This is the customer group that will be assigned to customers with valid VAT IDs that are from an EU country other than your own.

Group for Invalid VAT ID - This is the customer group that will be assigned to customers with invalid VAT IDs (both domestic and other EU countries).

Validation Error Group - This is the customer group that will be assigned to customers in the instance that have failed to have their VAT ID successfully verified.

Validate on Each Transaction - Options here are Yes or No. Setting this to Yes will mean that even if the customer has previously been validated, it will validate every time that they proceed through vat validation. Setting this to No will mean that once validated for first time, and customer group assignment takes place - it will not happen again.

Default Value for Disable Automatic Group Changes Based on VAT ID - it goes without saying that this is the most elusive of all the settings here.

Show VAT Number on Frontend - To enable VAT validation on the frontend (in addition to the backend), set this to Yes.


VAT Validation Customer Flow

  1. Customer enters their VAT ID
  2. The VAT ID is sent to the European Commissions server (you can manually valid here:
  3. European Commissions Server responds with the following results:
    • VAT VALID: Customers are then moved to the appropriate customer group depending on whether they are Domestic or Intra-union; either 'Group for Valid VAT ID - Domestic' or 'Group for Valid VAT ID - Intra-Union'
    • VAT INVALID: Customers are then moved into the 'Group for Invalid VAT ID'.


Setting up Customer Tax Classes

  1. Navigate to Sales > Tax > Customer Tax Classes. On the Customer Tax Class screen to view all currently configured customer tax classes. If you are setting up VAT validation for the first time, you may find you need to add another customer tax class to accommodate for when VAT validation is successful or not successful (if not vat validation is not successful you may find you want the customers to be classed as 'Retail' etc or 'Attempted VAT Validate' so you can follow up etc).

Note: A 'Customer Tax Class' is more or less a label, a way of identifying/classing customers to be used in tax rules later on.


Set up Tax Zones and Rates

  1. Navigate to Sales > Tax > Manage Tax Zones & Rates. This is where the tax rates / percentages live which are then married up with geographical locations (can specify a corresponding Country, State & Zip/Post Code). You can create as many rates as you like per country/state/region to represent all the rates that exist amongst products / customers etc. This is important because in the instance that VAT validation is successful you will want to ensure that VAT is not charged.
  2. To add a new rule, click +Add New Tax Rate. Typically, if you have your 'Standard VAT' rates already configured you will now need to create your 'Zero Rated VAT' / 'No VAT' rates for each corresponding/applicable country / state / region etc. Complete all required information for your new tax rate, ensuring that you give your new rate a descriptive tax identifier and click Save.


Set up Tax Rules

  1. Navigate to Sales > Tax > Manage Tax Rules. This is where all the pieces are married up to create a real world tax scenario (where a Customer Tax Class meets a Product Tax Class meets a Tax Rate). Typically, if you already have your Retail Customer tax rules created, you then want to create a new rule for the instance that VAT validation is successful and you don't want VAT to be charged.
  2. To add a new rule, click '+Add New Tax Rule', and select all the applicable components to build your successful VAT validation scenario (see example below).

Have more questions? Submit a request


Please sign in to leave a comment.