gotreu_default_country_reverse_charge

Updated 15 September 2026

On this page

Description

Decides whether a valid VAT number counts as a number from your default tax country. Those numbers pay VAT, while valid numbers from the other EU countries get the reverse charge. Return false to reverse charge valid VAT numbers from your own country as well.

This filter runs on your server, when the VAT is calculated after submitting. Always add the JavaScript filter with the same name as well, so the form shows the same result: gotreu_default_country_reverse_charge [JS]. With only one of the two, the form and the entry disagree, and a form with a Total field refuses to submit.

A form specific variant exists as well: add _FORMID to the hook name, for example gotreu_default_country_reverse_charge_3 for form 3.

Parameters

$is_default | Bool. True when the validated VAT number is from your default tax country

$form_id | Int. The ID of the form

Return

Bool. Return false to apply the reverse charge

Usage

Copy the below code to the functions.php of your child theme or to your snippet plugin. The complete example, with the JavaScript part, is in Reverse charge in your own country.

<?php
// Reverse charge valid VAT numbers from your own country on form 2.
add_filter( 'gotreu_default_country_reverse_charge_2', '__return_false' );

Since

version 1.1.0

Didn’t find what you were looking for?

Or contact support and I will help you out.

Scroll to Top