Mexico NSS (IMSS Number) Validator

Enter an NSS to check its 11 digits and Luhn check digit and read the sub-delegation and years, or paste a list of numbers to check many at once and download the results.

Runs in your browser. Your files never leave your device. See how to check

…

How to do it

  1. 1
    Enter the NSS

    11 digits.

  2. 2
    Read the result

    Check digit.

  3. 3
    See the structure

    Sub-delegation and years.

  4. 4
    Paste a list

    For batch checks.

  5. 5
    Review errors

    Expected digit.

  6. 6
    Download CSV

    For payroll.

About this tool

The Número de Seguridad Social (NSS) is the 11-digit number that the Mexican Social Security Institute assigns to each person for life. It identifies you in the IMSS when you work for an employer, when you use medical services, when you check your weeks of contributions, when INFONAVIT calculates your credit and when you retire. Employers need it to register new workers, and payroll systems print it on every payslip, so typing errors are common and cause rejected registrations, missing contributions or problems at the clinic. The number has a structure. The first two digits are the IMSS sub-delegation where you were first registered, the next two are the year of that registration, the following two are your year of birth, then come four consecutive digits, and the last digit is a check digit calculated from the first ten with the Luhn algorithm, the same method used for card numbers. That check digit lets software catch most single typing mistakes and swapped digits. This validator checks that an NSS has exactly 11 digits, recalculates the check digit and tells you whether it matches, and if not, which digit would be correct. It also reads the sub-delegation and the registration and birth years and warns when the birth year comes after the registration year, which usually means a wrong number. For payroll and HR teams, a batch mode checks a whole list pasted from a spreadsheet and lets you download the results as a CSV file, so you can fix errors before uploading the IDSE movements.

Who this is for

HR and payroll staff registering workers, accountants reviewing payroll files, workers checking the number on their payslip, and developers testing forms.

Structure

| Digits | Meaning | |---|---| | 1-2 | Sub-delegation of first registration | | 3-4 | Year of registration | | 5-6 | Year of birth | | 7-10 | Consecutive number | | 11 | Check digit (Luhn) |

How to get or confirm your NSS

Request it free on the IMSS website or app with your CURP and an email address; the IMSS sends a document with the number. The same number stays with you for life, even if you change employers. Never ask for a new one if you already have one, since duplicated numbers split your weeks.

How the check digit works

Double every second digit of the first ten, subtract 9 from results over 9, add everything, and the check digit is what brings the total to the next multiple of 10.

Common payroll errors

Typing one digit wrong, swapping two digits, using an old temporary number or mixing up workers with similar names are the usual causes of rejected movements in the IDSE system. Check the whole staff list with the batch mode before each upload, and ask new workers for the official IMSS document with their NSS instead of copying it from an old payslip.

Limits

A valid check digit means the number is well formed, not that it is assigned to that person. Confirm with the IMSS for official purposes.

Worked example

0108901234 needs a check digit of 6, so 01089012346 is valid and 01089012342 is not.

Quick facts

Frequently asked questions

How many digits does an NSS have?

Eleven.

How is the check digit calculated?

With the Luhn algorithm on the first ten digits.

Does a valid check digit prove the NSS is real?

No, only that it is well formed; the IMSS confirms assignment.

Can I have two NSS?

You should have one for life; duplicates split your contribution weeks.

Where do I get my NSS?

Free on the IMSS website or app with your CURP and email.

Is my data stored online?

No, it stays in this browser.

Guides for this tool

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