Spain's DNI, NIE and NIF validator

Check Spain's DNI, NIE or NIF and see what it holds beside the details the applicant declared.

Check one ID number

Spaces, dots, dashes and slashes are fine

Declared details

These fields are optional. Each filled field is compared with what the number holds.

The number is checked in this browser and is not sent or stored.

ID number result 12345678Z

Valid
Date of birth–
Sex–
Region–

The number is well built and its check digit matches, but this does not prove it belongs to the applicant.

CheckResult
Length and charactersPass
Number layoutPass
Check digitPass
DetailIn numberDeclaredResult
Date of birth––Not held in number
Sex––Not held in number
Region––Not held in number
Country–
Usual form–
Number kind–

Check a list of ID numbers

Up to 100 numbers for the selected country and ID number

Numbers this tool checks

Many national ID numbers contain a date of birth, sex or region, plus a check digit that can catch a mistyped digit. The table shows which details each number holds.

CountryID numberCheck digitDate of birthSexRegion
BrazilCPF✓––✓
BrazilCNPJ✓–––
ChileRUT / RUN✓–––
China居民身份证✓✓✓✓
CzechiaRodné číslo✓✓✓–
FranceNIR✓✓✓✓
IndiaAadhaar✓–––
IndonesiaNIK–✓✓✓
ItalyCodice fiscale✓✓✓✓
MexicoCURP✓✓✓✓
MexicoRFC✓✓––
PolandPESEL✓✓✓–
RomaniaCNP✓✓✓✓
SingaporeNRIC / FIN✓–––
SpainDNI / NIE / NIF✓–––

Run these checks on every application in your onboarding or credit decision flow. Start your trial

How Spain's DNI, NIE and NIF are checked

A DNI combines digits with a check letter chosen through a remainder calculation. An NIE begins with X, Y or Z, which are treated as digits for the same check, and NIFs beginning with K, L or M use it too. A company's NIF begins with a letter identifying its organisation type and ends with a Luhn check digit or its letter equivalent.

The result shows whether the number passes its checks and what details it contains beside the applicant's form details. Spain's DNI, NIE and NIF contain no date of birth, sex or region. A valid result means the number passed the checks shown, and only the issuing registry can confirm whether it was issued or belongs to the applicant.

Spain's ID number checks

How do I validate a Spanish DNI?

Enter the Spanish DNI to see whether it passes the number checks. A valid result means it passed those checks, and does not confirm that it was issued or belongs to the applicant.

What does Spain's DNI show about its holder?

Spain's DNI contains no date of birth, sex or region. The validator checks its format and check letter.

How does the check letter on a Spanish DNI work?

The DNI's digits determine a check letter through a remainder calculation. The validator checks whether the letter matches the digits.

Can I check Spain's NIE with this validator?

Yes. The validator checks an NIE's format and check letter, including the starting letter used for foreign residents.

Does a valid Spanish NIF confirm someone's identity?

No. A valid result means the NIF passed the checks shown. Only the issuing registry can confirm whether it was issued or belongs to the applicant.