UK VAT Number Formula
UK VAT Number Formula
Author
Discussion

Doofus

Original Poster:

31,405 posts

190 months

Thursday 18th February 2021
quotequote all
It's donkey's years since I've done this, and today this is just out of curiosity, because I can use the HMRC website to do this check, but:

I used to use a formula to check whether or not a VAT number was valid. *8, *7, *6 etc, minus 97 etc.

I've got two numbers, which I've checked and they are valid, but that formula doesn't work. Presumably there's another 'check digit' number as well as 97. Neither of the two VAT numbers I've got seem to have a common denominator.

Is there a / what is the new formula?


VEX

5,257 posts

263 months

Thursday 18th February 2021
quotequote all
No idea there was a formula.

My one from 2010 is a 97
But the new one i just got this month for a new business is 37

Doofus

Original Poster:

31,405 posts

190 months

Thursday 18th February 2021
quotequote all
VEX said:
No idea there was a formula.

My one from 2010 is a 97
But the new one i just got this month for a new business is 37
It always used to be:

Multiply the first seven digits by 8, 7, 6, 5, 4, 3, & 2 respectively, and add the totals up. Deduct 97 as many times as necessary until the result is negative. That negative number should equal the last two digits of your VAT number.

It doesn't seem to work any more, presumably because there are too many VAT numbers in circulation. So I'm assuming there are one or more alternatives to the 97.

plasticpig

12,932 posts

242 months

Thursday 18th February 2021
quotequote all
New formula here: https://library.croneri.co.uk/cch_uk/bvr/43-600

This does nor really test that a VAT number is valid of course. It's a test to rule out VAT numbers that are definitely invalid. The only true test of validity is the HMRC website or using the HMRC API.


Doofus

Original Poster:

31,405 posts

190 months

Thursday 18th February 2021
quotequote all
plasticpig said:
New formula here: https://library.croneri.co.uk/cch_uk/bvr/43-600

This does nor really test that a VAT number is valid of course. It's a test to rule out VAT numbers that are definitely invalid. The only true test of validity is the HMRC website or using the HMRC API.
Thank you, but I don't subscribe, so can't see that.

As I said; it's just for curiosity. I know I don't need it, but I used to use it back when the internet was all fields. Yes, I'm that old. frown

plasticpig

12,932 posts

242 months

Thursday 18th February 2021
quotequote all
Doofus said:
Thank you, but I don't subscribe, so can't see that.

As I said; it's just for curiosity. I know I don't need it, but I used to use it back when the internet was all fields. Yes, I'm that old. frown
You add 55 to the number before subtracting the 97 (in bold below) .

For VAT number 127 1786 06

1 × 8 = 8

2 × 7 = 14

7 × 6 = 42

1 × 5 = 5

7 × 4 = 28

8 × 3 = 24

6 × 2 = 12

Total = 133

     

133 + 55 = 188

188 - 97 = 91

91 - 97 = -06

So this VAT number is valid for a certain value of valid. You need to do both tests on the VAT number.. If passes both or fails both it is definitely invalid. If it passes one it may be valid.


Doofus

Original Poster:

31,405 posts

190 months

Thursday 18th February 2021
quotequote all
plasticpig said:
You add 55 to the number before subtracting the 97 (in bold below) .

For VAT number 127 1786 06

1 × 8 =?8

2 × 7 = 14

7 × 6 = 42

1 × 5 =?5

7 × 4 =?28

8 × 3 =?24

6 × 2 =?12

Total = 133

?????

133 + 55 = 188

188 - 97 = 91

91 - 97 = -06

So this VAT number is valid for a certain value of valid. You need to do both tests on the VAT number.. If passes both or fails both it is definitely invalid. If it passes one it may be valid.

Cool, thank you. smile

PF62

4,065 posts

190 months

Thursday 18th February 2021
quotequote all
Doofus said:
It doesn't seem to work any more, presumably because there are too many VAT numbers in circulation. So I'm assuming there are one or more alternatives to the 97.
They ran out of VAT numbers so had to start using previously cancelled numbers. However the last two digits in the VAT number are check digits, so to stop any confusion a revised formula was created to produce different check digits for the re-issued number.

If you want to check a VAT number is valid and who it belongs to, simply use this - www.gov.uk/check-uk-vat-number

Doofus

Original Poster:

31,405 posts

190 months

Thursday 18th February 2021
quotequote all
PF62 said:
If you want to check a VAT number is valid and who it belongs to, simply use this - www.gov.uk/check-uk-vat-number
Did you read any of this thread? wink