CPF Generator for Software Testing
Private by design — runs entirely in your browser
CPF (Cadastro de Pessoas Físicas) is the Brazilian taxpayer ID for individuals — an 11-digit number with two check digits. Toova generates mathematically valid CPFs entirely in your browser, perfect for seeding test databases, exercising form validators, and building demo apps. Nothing is uploaded, logged, or stored.
When you need a generated CPF
Most Brazilian software has a CPF field somewhere — sign-up forms, billing, KYC, e-commerce. During development you need values that pass the validator without being real people's CPFs. A generated CPF satisfies the check-digit algorithm but is not assigned to anyone at the Receita Federal, so it cannot be linked back to a real identity. Use it for fixtures, seed scripts, E2E tests, and demo screenshots. Never use a generated CPF as if it were a person's number — that is fraud.
How the check digits work
A CPF has nine base digits and two check digits. The first check digit is computed by multiplying each base digit by a descending weight from 10 down to 2, summing, taking the remainder modulo 11, and subtracting from 11 (or zero if the remainder is below 2). The second check digit applies the same rule to the ten preceding digits with weights from 11 down to 2. Toova performs this calculation locally; you can verify the result against the official rule published by the Receita Federal.
Bulk generation for fixtures and seeds
Switch to batch mode and generate up to twenty CPFs at once with one click. Each number is independently random, formatted with or without the standard 999.999.999-99 mask, and copyable individually or as a single block. Paste straight into a CSV, a seed script, or a fixture file. The maximum of twenty matches typical seeded user counts in unit and integration tests — for larger needs, you can simply click the generate button again.
Frequently Asked Questions
- Are the generated CPFs real?
- No. They satisfy the mathematical check-digit rule but are not assigned to any person by the Receita Federal. They will not appear in any tax record, ID database, or credit bureau.
- Can I use a generated CPF in production?
- Only for testing, seeding databases, or filling demo screens. Using a generated CPF to impersonate a real person, file fake invoices, or evade KYC is fraud and a crime under Brazilian law.
- Why does the validator on my form accept these?
- Form validators check the math, not the registry. A generated CPF passes the math, so the front-end validator accepts it. The Receita Federal's actual database lookup would reject it as unassigned.
- Does Toova store or log my generated CPFs?
- No. The numbers are generated in your browser using the cryptographic random source and never leave the page. Open the Network tab while you generate — you'll see zero outbound requests.
- What about repeated-digit CPFs like 111.111.111-11?
- Those pass the math but every real-world validator rejects them. Toova filters them out automatically so the values it produces look like normal CPFs.
- What is the difference between CPF and CNPJ?
- CPF identifies individuals (11 digits). CNPJ identifies companies and other legal entities (14 characters). They use related but distinct check-digit algorithms.