Check the control letter of a Spanish DNI or NIE locally in your browser - with no upload, even offline.
Running locally on your device ...
i
This tool performs only a mathematical checksum/format check. It is not an official identity, existence, or registry verification and not a request to any authority. Any additional information derived from the number's structure is based solely on the publicly documented encoding logic of the issuing authority.
No processing of your file contents takes place on any server. You need no data-processing agreement with gottrix to handle confidential or business documents.
Hosted in GermanyGlobal Content Delivery
Origin servers at Hetzner in Germany, delivered worldwide through a content delivery network. Your file contents are never transmitted in the process - they never leave your device.
The DNI (Documento Nacional de Identidad, 8 digits + control letter) identifies Spanish nationals; the NIE (Numero de Identidad de Extranjero, a leading X/Y/Z + 7 digits + control letter) identifies foreign residents. Both share the same official algorithm: the 8-digit number modulo 23, the remainder maps to a letter via a fixed table - the letters I, N, O and U deliberately never appear in it (risk of confusion with 1, Ñ, 0 and the letter N).
For a NIE, the leading letter is replaced by a digit before the calculation (X becomes 0, Y becomes 1, Z becomes 2), and the resulting 8-digit number is treated exactly like a DNI. This tool auto-detects from the first character whether a DNI or a NIE number was entered. Spaces and dashes in the input do not matter.
The whole calculation runs entirely locally in your browser in pure JavaScript - the number is not uploaded, not stored, and no foreign library is loaded from a CDN. You can download the result as a JSON file or read it directly.
Specifications
Specifications
Input formats
Text input
Output format
JSON
Batch processing
No
Processing
Locally in your browser (JavaScript)
File upload
None
In 3 steps
Paste the DNI or NIE number into the text field.
The tool auto-detects the type and recomputes the control letter.
Read the result or download it as JSON.
Limitations: This tool performs only a mathematical checksum/format check. It is not an official identity, existence, or registry verification and not a request to any authority. Any additional information derived from the number's structure is based solely on the publicly documented encoding logic of the issuing authority.
FAQ
Is my DNI or NIE number uploaded?
No. The check runs entirely locally in your browser; the number never leaves your device and is not stored.
Does a valid result confirm the person exists?
No. The tool only checks the mathematical control letter and the format - not a lookup against an official registry.
Why do the letters I, N, O and U never appear as the control letter?
To avoid confusion: I with 1, O with 0, and because of the Spanish letter Ñ, N is also skipped. The official table deliberately leaves these four out.
How does the tool tell a DNI from a NIE apart?
By the first character: input starting with a digit is checked as a DNI; input starting with X, Y or Z is checked as a NIE.