How to Use the France NIR Checksum Validator
- Type or paste a 15-digit NIR (numéro de sécurité sociale) into the box above — spaces are fine, the tool strips them automatically.
- Click Check. The tool verifies the 15-digit structure and recomputes the official mod-97 control key.
- Read the decode table for the encoded gender, birth year, and birth month.
- Nothing you type is uploaded anywhere — the whole calculation runs as plain JavaScript in your browser tab.
How a NIR Is Built
France's NIR (numéro d'inscription au répertoire), commonly called the "numéro de sécurité sociale," is a 15-digit number issued by INSEE and used for social security, health insurance (the Carte Vitale), and payroll. Its structure encodes real information:
- Digit 1: Gender — 1 for male, 2 for female.
- Digits 2–3: The last two digits of the birth year.
- Digits 4–5: The birth month (01–12).
- Digits 6–7: The département (region) of birth — usually two digits, but Corsican départements use the letters 2A or 2B instead of a number.
- Digits 8–10: An INSEE commune (town) code within that département.
- Digits 11–13: A sequential order number for people registered in the same place and month.
- Digits 14–15: A 2-digit control key (the "clé"), computed from the preceding 13 digits.
The Checksum: Mod-97
The control key is calculated as
97 - (first 13 digits, as one number, mod 97)Worked Example
295109912611193What This Tool Does NOT Do
This checks structure and the mod-97 control key only. It does not query CNAV, CPAM, Ameli, or any other French government system, and cannot confirm a NIR is actually issued or belongs to a real person. The département, commune, and order-number fields are shown as raw digits rather than decoded to place names — a full département/commune lookup would require the complete INSEE "Code Officiel Géographique" reference table (hundreds of entries, updated periodically as communes merge), which is out of scope for this structural checker. This tool also does not attempt to distinguish NIRs issued under special schemes (e.g., temporary numbers for people born abroad, which use a different, non-birth-year-based numbering convention).
Common Mistakes
- Forgetting the Corsican département letter substitution (2A→19, 2B→18) when hand-checking the key
- Dropping the leading zero from a single-digit month or département, which shifts every subsequent field
- Mixing up the 13-digit "identity" portion with the full 15-digit number when computing the key by hand
- Assuming a valid control key proves the NIR is currently active — it doesn't
Frequently Asked Questions
Is my NIR uploaded anywhere? No — everything runs locally in your browser tab.
Does this tool tell me which town someone was born in? No — it shows the raw commune code but doesn't map it to a name.
Does a valid control key mean the NIR is real? No — it means the number is internally consistent, not that it's actually issued or active.
Is this tool free? Yes, completely free, with no login and no usage limit.