en

CPF/CNPJ Brazil

Check the check digits of a Brazilian CPF or CNPJ number locally in your browser - with no upload, even offline.

Running locally on your device ...

This tool performs only a mathematical checksum/format check. It is not an official identity, existence, or registry verification and not a request to any authority. Any additional information derived from the number's structure is based solely on the publicly documented encoding logic of the issuing authority. In addition: only the classic all-numeric CPF/CNPJ format is checked; a newer alphanumeric CNPJ is honestly reported as unsupported rather than mis-evaluated.

Factual note, not legal advice: Brazil's LGPD (Lei Geral de Protecao de Dados) treats a CPF or CNPJ number as personal data. Every check above runs entirely on your device - your number is never uploaded to a server, gottrix's or anyone else's.

You do not have to take our word for it: switch to flight/offline mode after the page has loaded once and the check still works; open your browser's DevTools Network tab while checking a number and you will see zero requests carrying it; gottrix's Content-Security-Policy (connect-src) technically blocks this page from sending file or form data to any other origin.

Running locally on your device ...

0%

Is my file uploaded?

No. Everything runs in your browser - your file never leaves your device. How this is verifiable

No upload100% local
Your content stays with youno third-party access
Hosted in GermanyGlobal Content Delivery
Independently auditedTLS A+ · HTTP headers A+

CPF (Cadastro de Pessoas Fisicas, 11 digits) identifies natural persons to the Brazilian tax authority Receita Federal; CNPJ (Cadastro Nacional da Pessoa Juridica, 14 digits) identifies companies. Both numbers end in two check digits computed from the preceding digits via a publicly documented modulo-11 method. This tool auto-detects a CPF vs a CNPJ from the digit count and recomputes the check digits.

The check catches two failure modes: a wrong check digit (typo or made-up number) and the officially blacklisted all-same-digit sequences (e.g. 111.111.111-11), which pass the modulo-11 math but are never issued by Receita Federal. Dots, slashes and dashes in the input do not matter - the tool only reads the digits.

The whole calculation runs entirely locally in your browser in pure JavaScript - the number is not uploaded, not stored, and no foreign library is loaded from a CDN. That matters precisely for a tax ID: it does not belong in an external online form. You can download the result as a JSON file or read it directly.

Specifications

Specifications
Input formatsText input
Output formatJSON
Batch processingNo
ProcessingLocally in your browser (JavaScript)
File uploadNone

In 3 steps

  1. Paste the CPF or CNPJ number into the text field.
  2. The tool auto-detects the type and recomputes the check digits.
  3. Read the result or download it as JSON.

Limitations: This tool performs only a mathematical checksum/format check. It is not an official identity, existence, or registry verification and not a request to any authority. Any additional information derived from the number's structure is based solely on the publicly documented encoding logic of the issuing authority. In addition: only the classic all-numeric CPF/CNPJ format is checked; a newer alphanumeric CNPJ is honestly reported as unsupported rather than mis-evaluated.

FAQ

Is my CPF or CNPJ number uploaded?

No. The check runs entirely locally in your browser; the number never leaves your device and is not stored.

Does a valid result confirm the number actually exists?

No. The tool only checks the mathematical check digits and the format - not a lookup against the Receita Federal registry. A mathematically valid number may still never have been issued.

Why are 111.111.111-11 & co. treated as invalid even though the math checks out?

Because Receita Federal officially never issues all-same-digit sequences, even though they pass the modulo-11 math. This tool reproduces that blacklist.

Does the tool auto-detect whether I entered a CPF or a CNPJ number?

Yes, from the digit count: 11 digits = CPF, 14 digits = CNPJ. Dots, slashes and dashes are ignored.

Does the tool also check the new alphanumeric CNPJ format?

No, honestly not: it only checks the classic all-numeric format. An alphanumeric CNPJ is reported as unsupported rather than mis-evaluated.

Related tools

Calculate a checksum · Calculate an HMAC · UUID generator