Brazilian CPF Generator & Validator
Generate and validate mathematically valid Brazilian CPF (Cadastro de Pessoas Físicas) numbers strictly for software development, test automation, and QA verification. Fully compliant with Receita Federal Modulo 11 check-digit rules.
Como Gerar e Validar CPF Válido para Testes (Passo a Passo)
Gere números de CPF válidos com cálculo matemático exato dos dígitos verificadores para testes de software e desenvolvimento de sistemas:
Escolha se deseja o CPF gerado com máscara de formatação (000.000.000-00) ou apenas dígitos numéricos para preenchimento de banco de dados.
Selecione o estado brasileiro desejado para determinar a nona posição do documento, ou selecione 'Aleatório'.
O gerador executa o algoritmo oficial do Módulo 11 da Receita Federal, calculando instantaneamente os dois dígitos verificadores válidos.
Clique no botão 'Copiar' para colar no seu ambiente de homologação, ou alterne para a aba 'Validador' para testar a validade de qualquer documento.
How Does the Brazilian CPF Modulo 11 Algorithm Work?
The Brazilian CPF (Cadastro de Pessoas Físicas) is an 11-digit individual taxpayer identification number structured as ABC.DEF.GHI-JK. The first 8 digits are the core sequential registration number, the 9th digit designates the regional tax jurisdiction (Região Fiscal da Receita Federal), and the last two digits (J and K) are verification check digits computed through Modulo 11 arithmetic.
1. Calculation of the First Verifier Digit (J)
Each of the first 9 digits is multiplied by descending sequential weights from 10 down to 2. The products are summed together:
Divide Sum 1 by 11. If the remainder is less than 2, digit J = 0. Otherwise, digit J = 11 - remainder.
2. Calculation of the Second Verifier Digit (K)
The calculation repeats incorporating the newly verified digit J, this time multiplying the first 10 digits by descending weights from 11 down to 2:
Divide Sum 2 by 11. If the remainder is less than 2, digit K = 0. Otherwise, digit K = 11 - remainder.
Official Brazilian Fiscal Regions Map (Receita Federal)
The 9th digit of any valid CPF identifies the administrative regional tax district where the document was originally registered:
| Digit 9 | Fiscal Region | States Covered |
|---|---|---|
| 1 | 1st Region | Federal District, Goiás, Mato Grosso do Sul, Mato Grosso, Tocantins |
| 2 | 2nd Region | Pará, Amazonas, Amapá, Rondônia, Roraima, Acre |
| 3 | 3rd Region | Ceará, Maranhão, Piauí |
| 4 | 4th Region | Pernambuco, Alagoas, Paraíba, Rio Grande do Norte |
| 5 | 5th Region | Bahia, Sergipe |
| 6 | 6th Region | Minas Gerais |
| 7 | 7th Region | Rio de Janeiro, Espírito Santo |
| 8 | 8th Region | São Paulo |
| 9 | 9th Region | Paraná, Santa Catarina |
| 0 | 10th Region | Rio Grande do Sul |
Notice for Developers & QA Teams (LGPD Compliance)
This utility is engineered strictly for software engineers, database architects, and QA analysts conducting automated unit testing, mock dataset generation, and form input validation. All generated numbers are synthesized algorithmically in your browser and do not represent active individuals registered with the Brazilian Federal Revenue Service (Receita Federal do Brasil).
Frequently Asked Questions (FAQ)
What is a Brazilian CPF number and what is its standard format?
The CPF (Cadastro de Pessoas Físicas) is an 11-digit national taxpayer identification number assigned by the Brazilian Federal Revenue Service (Receita Federal). It is commonly represented either as 11 consecutive digits (00000000000) or formatted as 000.000.000-00, where the final two digits are calculated check verifiers.
Are the CPF numbers generated by this tool genuine citizens?
No. This tool algorithmically synthesizes fictitious, mathematically valid numbers strictly for software developers, QA testers, and database designers to test form validation, checkout flows, and backend logic without exposing real citizens personal identification data.
How does the Modulo 11 validation algorithm calculate the two check digits?
The first check digit (10th digit) is computed by multiplying the first 9 digits by descending weights from 10 to 2, dividing the sum by 11, and taking 11 minus the remainder. The second check digit (11th digit) repeats the process over the first 10 digits using weights from 11 down to 2.
How can you identify which Brazilian state issued a CPF?
The 9th digit (the digit directly preceding the hyphen in formatted CPFs) designates the Fiscal Region of registration. For instance, digit 8 corresponds to São Paulo, digit 7 to Rio de Janeiro/Espírito Santo, and digit 0 to Rio Grande do Sul.
Why does the validator reject repeated numbers like 111.111.111-11?
Even though repeated identical numbers like 111.111.111-11 or 000.000.000-00 can theoretically satisfy the basic Modulo 11 mathematical formula, they are explicitly blacklisted and classified as invalid by the Receita Federal to prevent automated spam and fraud.