NIF is valid (ES)
What this tool does
This tool checks if a Spanish tax identification number (NIF) follows the correct format and mathematical rules. It does not verify if the number is currently active or assigned to a specific person, only that it is structurally valid.
Keep in mind that a valid format does not guarantee the number is in use or belongs to the person claiming it. For foreign identification numbers (NIE), this tool may not work correctly as the rules differ from the standard Spanish tax number.
Common uses
- Validating customer information during account sign-up.
- Checking the format of business registration numbers before processing invoices.
- Automating form validation to prevent typos in tax ID fields.
Input data
| Parameter | Required | Example | Description |
|---|---|---|---|
nif | Yes | 44016116G | Enter the 9-character Spanish tax identification number as text (e.g. '44016116G'). This field is required. If the number is too short, contains letters in the wrong place, or has an incorrect check letter, the tool will indicate it is invalid. |
Output data
| Field | Description |
|---|---|
result | Returns 'true' if the NIF format and check digit are correct, or 'false' if they are not. For example, it returns 'true' for a valid format like '44016116G' and 'false' for an invalid one like '44016116M'. |