UK NHS Number Validator (Modulus 11 Check)

Paste one or more NHS numbers to test the length and the modulus 11 check digit and to see the standard layout.

Działa w Twojej przeglądarce. Twoje pliki nigdy nie opuszczają urządzenia. Zobacz, jak to sprawdzić

…

Jak to zrobić

  1. 1
    Paste the numbers

    Type or paste one NHS number per line.

  2. 2
    Run the check

    The tool tests the length and the check digit.

  3. 3
    Review the verdicts

    Each NHS number is marked passed or failed.

  4. 4
    See the layout

    A valid number is shown as 3-3-4.

  5. 5
    Fix the errors

    Compare with the expected check digit.

O tym narzędziu

The NHS number is the ten-digit identifier that follows a patient through health services in England, Wales and the Isle of Man. The tenth digit is a check digit calculated from the first nine with weights 10 down to 2 and a modulus of 11. It is written in groups of three, three and four digits. This validator tests the length, the digits and the check digit and shows the standard layout. It cannot tell whether a number belongs to a patient.

Who this is for

Health data teams who clean lists, software developers who validate entry fields, receptionists and administrators who copy numbers from letters, and researchers who test data quality with made-up numbers.

The format

The standard layout is three digits, a space, three digits, a space and four digits, for example 943 476 5919. The number has no meaning in its digits: the number does not show age, region or sex. The final digit is the check digit. Services in other parts of the UK use different identifiers, such as the CHI number in Scotland and the Health and Care number in Northern Ireland.

The calculation

Multiply the first nine digits by 10, 9, 8, 7, 6, 5, 4, 3 and 2. Add the products. Divide the sum by 11 and take the remainder. Subtract the remainder from 11 to get the check digit. If the result is 11, the check digit is 0. If the result is 10, the number cannot be valid, because there is no single digit for 10, and such numbers are never issued. For 943476591 the sum is 90 + 36 + 24 + 28 + 42 + 30 + 20 + 27 + 2 = 299, the remainder when divided by 11 is 2, and 11 − 2 = 9, so the check digit is 9 and the number 9434765919 passes.

Reading the result

The tool tells you if the length is wrong, if there is a character that is not a digit, if the number would need a check digit of 10, or if the check digit does not match. For a failed check, it shows the digit that was expected. That makes it easy to see whether the problem is the last digit or an earlier one.

Why it matters

A wrong NHS number can attach a result or a letter to the wrong person's record, which is a patient safety problem. Systems validate the check digit when a number is typed to catch mistakes early. A check does not replace confirming a patient's identity by name, date of birth and address through the national service.

How to use it

Paste one number per line. Spaces are removed. Each line is marked valid or not. A valid number is shown in the 3-3-4 layout. The sample has valid and invalid numbers, so you can try the tool at once.

Worked example

The number 943 476 5919 passes. The number 943 476 5918 fails and the tool shows that the expected check digit is 9. A number with nine digits fails because of its length.

Privacy

An NHS number is personal health information when it is linked to a person. Use made-up numbers for tests. The tool works in your browser and keeps nothing.

Limits

This is a technical check and not medical or legal advice.

Przykład z rozwiązaniem

The NHS number 943 476 5919 passes the modulus 11 check, while 943 476 5918 fails because the expected check digit is 9.

W skrócie

Najczęstsze pytania

How long is an NHS number?

Ten digits, written as 3-3-4.

How is the check digit calculated?

The first nine digits are multiplied by 10 down to 2, added, and reduced with modulus 11.

What if the check comes out as 10?

Then the number is not valid. Such numbers are not issued.

Does a pass mean the person exists?

No. It only checks the structure.

Do other UK nations use it?

Scotland and Northern Ireland have their own identifiers.

Is my data stored?

No. The check runs in your browser.

Całkowicie za darmoBez opłat i rejestracji
Pliki zostają prywatneWszystko działa w Twojej przeglądarce
Łatwo w Twoim językuDostępne w wielu językach