Nouplo

Spanish DNI and NIE letter calculator

The DNI letter, worked out.

Examples temporarily replace the input and settings. You can restore your previous work.

0 characters
Output
Paste or type above to see the result here.

Your files stay on your device

This tool runs entirely in your browser. What you paste is processed on your device and is never sent to a server, so it is safe to use with tokens, keys and unpublished text.

Example

Worked example — Spanish DNI and NIE letter calculator

Use the following inputs and settings. Keep other settings at the page defaults.

Item Value
Input 12345678
kind dni
Output → 12345678Z — letter worked out for the number typed
Output 12345678 ÷ 23 = 536768 remainder 14
Output Letter: place 14 in TRWAGMYFPDXBNJZSQVHLCKE (counting from 0): Z
Output A correct check digit only means the number is well-formed; it doesn’t mean the number exists or belongs to anyone. Nothing is sent anywhere: the check runs in your browser.

Expected result — → 12345678Z — letter worked out for the number typed

How it works

  1. Paste one number a line; dots, dashes and spaces are fine.
  2. Each is checked for its length and its check digits.
  3. The result shows each step of the calculation, and where a number fails.

Frequently asked questions

How is the DNI letter calculated?
Divide the eight digits by 23 and take the remainder: 0 is T, 1 is R, 2 is W … 22 is E. 12345678 ÷ 23 leaves 14, the letter Z.
And a NIE?
An NIE starts with X, Y or Z, which count as 0, 1 and 2 in front of the seven digits; then the same rule gives the letter.
Does a valid check digit mean the number exists?
No — only that it is correctly written. Whether it was issued, and to whom, only the issuing authority can say. The checker never makes up numbers either: it checks the ones you type.
Is anything uploaded?
No. The check is worked out in your browser, and nothing you type leaves your computer.

Made for a specific use

Related tools