Certificate Validator
Validate birth, marriage, and death certificate registration numbers. QA.
About the Certificate Validator
The Certificate Validator checks if a birth, marriage, or death certificate registration number is mathematically valid. The registration has 32 digits with 2 verification digits calculated using the modulo 11 algorithm.
This tool is useful for developers who need to validate certificate registration formats in registration systems. The validation is purely mathematical and does not query any notary office database.
Anatomy of Brazilian Civil Certificate ID
The national certificate identification matrix features 32 digits across 9 fields:
| Position | Field | Length | Meaning & Rule | Example |
|---|---|---|---|---|
| 1 to 6 | Registry Office ID | 6 digits | Unique nationwide CNS code of the civil notary | 123456 |
| 7 to 10 | Collection & Service | 4 digits | Own collection (01) and Civil Registry service (55) | 0155 |
| 11 to 14 | Registration Year | 4 digits | Four-digit registration year | 2024 |
| 15 | Book Type | 1 digit | 1: Birth, 2: Marriage, 3: Religious Marriage, 4: Death, 5: Stillborn | 1 |
| 16 to 20 | Book Number | 5 digits | Notary registry book number | 00123 |
| 21 to 23 | Page Number | 3 digits | Page inside the designated book | 045 |
| 24 to 30 | Entry Number | 7 digits | Sequential entry registration number | 0001234 |
| 31 & 32 | Check Digits | 2 digits | Dual Modulo 11 check digits under CNJ rules | 87 |
Civil Certificate Checksum Algorithm (CNJ Ruling 63/2017)
Verification applies two sequential Modulo 11 steps with cyclic weights:
CD1 = (Sum1 % 11 == 10 ? 1 : Rem1 % 10); CD2 = (Sum2 % 11 == 10 ? 1 : Rem2 % 10)
- 1. For CD1, multiply first 30 digits right to left by weights 2 to 10.
- 2. If remainder modulo 11 is 10, CD1 = 1; otherwise CD1 = remainder % 10.
- 3. For CD2, append CD1 as position 31 and multiply all 31 digits right to left by weights 2 to 11.
- 4. If remainder modulo 11 is 10, CD2 = 1; otherwise CD2 = remainder % 10.
- 5. Final check digits occupy positions 31 and 32.