Skip to main content

France INSEE / NIR Validator

Online validator for French INSEE / NIR (Social Security) numbers according to Modulo 97 specifications.

How does INSEE / NIR validation work?

Validation checks the 15-character length, gender digit (1, 2, 3, 4, 7, 8), department format (including Corsica 2A and 2B), commune and serial codes.

It applies the official Modulo 97 checksum algorithm, converting 2A to 19 and 2B to 18 to verify the final 2-digit control key.

Anatomy & Structure of French NIR / INSEE (15 Digits)

The national social security register number (NIR) features 15 characters across 7 official blocks:

PositionFieldLengthMeaning & RuleExample
1Gender1 digit1 for male; 2 for female1
2 & 3Birth Year2 digitsLast two digits of birth year85
4 & 5Birth Month2 digitsMonth of birth (01 to 12)12
6 & 7Department2 charsDepartment code (01-95, 2A/2B Corsica, 97/98 overseas, 99 abroad)75
8 to 10Commune Code3 digitsINSEE municipality code108
11 to 13Birth Act Order3 digitsSequential birth certificate number in that month/commune042
14 & 15Control Key2 digitsModulo 97 checksum digits51

NIR / INSEE Validation Algorithm (Modulo 97)

INSEE computes the 2-digit control key over the first 13 characters using Modulo 97:

Key = 97 - (BaseValue13 % 97)
  1. 1. Extract the first 13 characters of the NIR.
  2. 2. If the department is 2A (South Corsica), replace "2A" with numeric "19".
  3. 3. If the department is 2B (Upper Corsica), replace "2B" with numeric "18".
  4. 4. Compute integer remainder modulo 97: Remainder = BaseValue13 % 97.
  5. 5. Subtract remainder from 97: Key = 97 - Remainder.
  6. 6. Pad with leading zero if needed and verify match against digits 14 and 15.

Frequently Asked Questions