Test data for Brazilian software
EN
Fictitious data for software testing. Using fake documents for fraud is a crime in Brazil (Penal Code, arts. 297–299, 307).

RENAVAM generator and validator

Generate fictitious Brazilian vehicle registry codes (RENAVAM) with a valid check digit for fleet, insurance and vehicle-inspection software tests — and validate whole lists, including legacy 9-digit codes.

—

Up to 1000 items at once. Everything is generated in your browser.

How to use

  1. On the Generate tab, pick a Quantity (1 to 1000) and click Generate. Each code has 11 digits with no punctuation, as printed on the vehicle document.
  2. Click Copy to put the codes on your clipboard.
  3. To build fixtures or seed a test database, use Export CSV or Export JSON.
  4. On the Validate tab, paste one code per line. 9-digit codes are accepted and left-padded with 00.
  5. Click Validate: each line shows valid or invalid with the reason (length, characters, repeated digits or check digit).

How it works

What RENAVAM is

RENAVAM stands for Registro Nacional de Veículos Automotores, Brazil’s national motor-vehicle registry, run by the National Traffic Secretariat (SENATRAN) together with the state traffic departments (Detrans). Every registered vehicle gets a RENAVAM code, printed on its registration certificate (CRLV). Unlike the licence plate, the code stays with the vehicle for its whole life, through changes of owner or plate. Insurers, rental companies, lenders and vehicle-tax lookups in Brazil all ask for it, so validating it correctly saves a lot of support tickets.

Format: 11 digits (plus legacy 9)

Current codes have 11 digits: 10 base digits and 1 trailing check digit. Older vehicles were issued 9-digit codes; to check them, left-pad with two zeros (00) and apply the same rule. The validator on this page does that automatically and tells you when the input was a legacy code.

Check-digit algorithm

SENATRAN does not publish an open specification of this calculation on the portals we checked; the rule below is the one widely used in the industry and is exactly what this tool implements.

  1. Multiply the first 10 digits, left to right, by the weights 3, 2, 9, 8, 7, 6, 5, 4, 3, 2.
  2. Add the products and multiply the sum by 10.
  3. Take the remainder of dividing by 11. If the remainder is 10, the check digit is 0; otherwise it is the remainder itself.

Worked example

Base: 9752674309.

Digit9752674309
Weight3298765432
Product2714451642422012018

Sum: 27 + 14 + 45 + 16 + 42 + 42 + 20 + 12 + 0 + 18 = 236. Times 10: 2360. 2360 mod 11 = 6 (11 × 214 = 2354). Full code: 97526743096.

Legacy example: 639258719 becomes 00639258719. The products add up to 233; × 10 = 2330; 2330 mod 11 = 9, which matches the last digit, so the code is valid.

How this tool behaves

  • The generator draws 10 random digits, skips bases made of one repeated digit and appends the check digit. As with real codes, the base may start with zero.
  • The validator accepts dots, hyphens and spaces, requires 11 digits (or 9, padded with 00), rejects repeated sequences and verifies the check digit.
  • Processing happens in your browser; nothing is sent to a server.

Passing the check only means the code is structurally valid — there is no lookup against the RENAVAM system. Generated codes are fictitious and meant for software testing only.

FAQ

Is RENAVAM the same as the licence plate?

No. The plate is the visible identifier and can change — for example when converted to the Mercosur format. RENAVAM is the registry record code and stays the same for the vehicle’s entire life. Model them as two separate fields in your schema.

What should I do with 9-digit RENAVAM codes?

They are the legacy format. To validate, left-pad with two zeros and apply the 11-digit rule. When storing, normalise everything to 11 digits and keep it as text so leading zeros are not lost. The validator here performs that normalisation automatically.

Can I store RENAVAM as an integer?

Avoid it. Many codes start with zero, and a numeric column drops those zeros, which breaks check-digit validation and exact-match lookups. Use an 11-character text column and check it with a pattern such as ^\d{11}$ before computing the check digit.

Does a valid code belong to a real vehicle?

The tool does not query any Detran or SENATRAN service; it only checks structure and the check digit. Generated codes are random and fictitious, intended for form tests, QA, demos and staging databases. Do not use them in documents, listings or transactions involving real vehicles.

Why does the algorithm multiply the sum by 10?

Because 10 ≡ −1 (mod 11), computing (sum × 10) mod 11 gives the same result as 11 − (sum mod 11), a form you may see in other write-ups. In the example, 236 mod 11 = 5 and 11 − 5 = 6 — the same digit. When the result is 10 (or 11 in the second form), the check digit becomes 0.

Sources

Related tools

Updated 2026-11-13 · Rafael Lima