Everyday Tools

NHS Numbers: How the Modulus 11 Check Digit Protects Patient Records

How the ten-digit NHS number is built, how the check digit is calculated and why a quick validation helps reduce errors in health records.

Saizul Amin
Saizul Amin23 Oct 2026 · 3 min read
NHS Numbers: How the Modulus 11 Check Digit Protects Patient Records

NHS Numbers and the Modulus 11 Check

The NHS number identifies a patient across health services in England, Wales and the Isle of Man. Getting it right matters: a wrong digit can attach a test result to the wrong person. The UK NHS Number Validator tests the check digit in your browser.

The format

An NHS number has ten digits. It is normally shown in groups of three, three and four, for example 943 476 5919. The digits carry no meaning: there is no region code, no age and no sex in the number. Other parts of the UK use different identifiers: Scotland has the CHI number and Northern Ireland has the Health and Care number.

The check digit

The tenth digit is calculated from the first nine. Multiply them by 10, 9, 8, 7, 6, 5, 4, 3 and 2. Add the products. Divide the total by 11 and find the remainder. Subtract the remainder from 11. 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 to represent 10, and such numbers are never issued.

A worked example

For the first nine digits 943476591 the products are 90, 36, 24, 28, 42, 30, 20, 27 and 2. The sum is 299. Dividing by 11 leaves a remainder of 2, and 11 minus 2 gives 9, so the check digit is 9 and the full number is 9434765919. If the last digit were 8, the number would fail.

Why validation helps

Health records are matched by number, and a mismatch can have serious results. Validation when the number is typed catches transpositions and single-digit mistakes immediately. Clinical systems do this, and so should any data tool that handles NHS numbers, for example a spreadsheet used in a research project or an audit. For the identity of the patient, systems also match the name, date of birth and postcode through the national service.

Using the validator

Paste one number per line. Spaces are ignored. The tool tests the length, the characters and the check digit. A valid number is shown in the standard layout. A failed line shows the reason, and for a wrong check digit it shows the digit that was expected. A message appears for numbers whose check calculation gives 10.

What it does not check

A correct number is not proof that a person exists or that the number belongs to the person in front of you. The tool does not connect to any health service. Do not paste real patient data into tools that you do not control. For tests, use made-up numbers. The sample numbers in the tool are for demonstration.

Typical mistakes

Typing errors, a missing digit at the end of a line, and a space or a letter in the wrong place are the usual causes of failure. Another is confusing the NHS number with a hospital number or a GP practice reference, which have different formats. Importing from a spreadsheet can remove leading zeros, although an NHS number may start with any digit.

Limits

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

For data teams

When you receive a file with NHS numbers, validate the whole column before analysis and report the share that fails. A failure rate above a percent or two usually shows a systematic problem, such as leading characters removed or digits in the wrong field. Record the validation date and the tool you used in your data quality notes so that the work can be repeated.

Completely freeNo cost, no sign-up
Files stay privateEverything runs in your browser
Easy in your languageAvailable in many languages