CPF Generator and Validator

Validate a Brazilian CPF and generate valid CPF numbers for testing, with the check digits and the tax region. Free, in your browser, nothing is sent.

Generate test numbers
Generated numbers are fictitious and only for testing software and forms. Using them to pass yourself off as someone, open accounts or register anything is illegal.

What it does


The CPF (Cadastro de Pessoas Físicas) is the Brazilian individual taxpayer number issued by the Receita Federal. It has 11 digits written as 000.000.000-00: nine base digits and two check digits, each calculated with modulo 11. The ninth digit shows the tax region where it was issued, from 0 (Rio Grande do Sul) to 9 (Paraná and Santa Catarina). Sequences of identical digits, such as 111.111.111-11, pass the formula but are never issued.

Everything happens in your browser: the numbers you type are not sent or stored.

Frequently asked questions


Does a valid number mean that the person or company exists?
No. It only means the check digits are correct, which catches typing mistakes. Whether the number was actually issued, and to whom, can only be checked with the authority that issues it.

What are the generated numbers for?
For testing: filling in forms in development, testing databases and validation code. They are made at random with correct check digits, so by chance one may coincide with a real number. Never use them to identify yourself, sign up for anything or deceive anyone.

How does a check digit work?
It is calculated from the other digits with a fixed formula, usually multiplying each digit by a weight and taking the remainder of a division (modulo 11, or modulo 23 for the Spanish DNI letter). If one digit is typed wrong or two are swapped, the check digit no longer matches.

Other documents