Citizen Card Validator

Portuguese Citizen Card document number — 12 characters, digits plus a 3-letter series.

Portugal Validation Generation

How validation works

The validator normalises the document number, verifies the body against the expected12-character shape and recomputes the Citizen Card check digit.

Install the package

bash
dotnet add package DocumentNumber.Portugal.CitizenCard.Validator

Validator in C#

Program.cs
using DocumentNumber.Portugal.CitizenCard.Validator;

var validator = new CitizenCardValidator();
var isValid = validator.Validate("835099610IP8");

Console.WriteLine(isValid ? "Valid" : "Invalid");

Live example

835099610IP8 — a real Citizen Card value accepted by the validator

Try Citizen Card validation

Runs the exact same library code your application uses. Nothing you enter is stored.

Document type Citizen Card Portugal
Example: 835099610IP8 — demo input is never stored.

Frequently asked questions

What is Citizen Card?

Portuguese Citizen Card document number — 12 characters, digits plus a 3-letter series.

How does Citizen Card validation work?

The validator normalises the document number, verifies the body against the expected12-character shape and recomputes the Citizen Card check digit.

How do I install the Citizen Card validator package?

dotnet add package DocumentNumber.Portugal.CitizenCard.Validator

Is the value I enter in the demo stored?

No. Demo inputs are processed in memory for the current request only and are never persisted or shared.

Related document types