Skip to main content

UTR Validator (UK)

Validate the structural integrity, length, and Modulus 11 check digit of UK HMRC Unique Taxpayer References.

About Unique Taxpayer Reference (UTR) Validation

UTR validation checks whether a reference complies with the mathematical rules and structure established by HM Revenue & Customs (HMRC) in the United Kingdom.

The validator strips administrative prefixes such as 'K', spaces, and hyphens, extracts the leading check digit, and recalculates the weighted sum using HMRC's official formula.

Anatomy & Structure of the UK UTR (10 Digits)

Official structure regulated by HM Revenue & Customs and the Taxes Management Act 1970:

PositionFieldLengthMeaning & RuleExample
1Check Digit1 digitOfficial check digit calculated via HMRC Modulus 11 over the subsequent 9 digits1
2 to 10Taxpayer Account9 digitsUnique central numeric sequence assigned to the tax record955839661

HMRC Modulus 11 Verification Algorithm

Positional weighted calculation applied to positions 2 through 10:

Sum = ∑(d[i+1] * W[i]) | Remainder = Sum % 11 | Check Digit = '21987654321'[Remainder]
  1. 1. Extract the 9 core digits (positions 2 through 10).
  2. 2. Multiply each digit by the weights [6, 7, 8, 9, 10, 5, 4, 3, 2] from left to right.
  3. 3. Sum all products and calculate the remainder modulo 11.
  4. 4. Map the remainder to the lookup table '21987654321'. If remainder is 0, check digit is 2; if 1, check digit is 1; for remainders 2 through 10, check digit is (11 - remainder).
  5. 5. The resulting check digit must match position 1 of the UTR.

Frequently Asked Questions & Technical Specifications