Generatore Codice Fiscale
Genera codici fiscali italiani validi per persone fisiche e giuridiche. Database completo di tutti i comuni italiani con codici catastali.
Come utilizzare Generatore Codice Fiscale
Choose subject type
Select the "Physical Person" sheet to generate a 16-character tax code, or the "Legal Person" sheet to generate an 11-digit VAT number.
Fill in your personal details
For personal information, enter surname, name, date of birth and gender. Search the place of birth by starting to type in the designated box: a dropdown menu with corresponding municipalities and their respective census codes will appear.
Generate your tax code
Click on "Generate Tax Code". Alternatively, use "Generate Random" to get a code with fictional data without filling out the form. The system automatically calculates the check digit according to DM 12/03/1974.
Analyze code composition
The result shows the visual breakdown of the code: 3 letters for surname, 3 for name, 2 digits for year, 1 letter for month, 2 digits for day (increased by 40 for women), 4 characters for municipality and final control character.
Advanced Features
Activate the "Teaching Mode" to see all calculation steps step by step. Use the "Omocodie" button to generate 128 Omocode variations of the code. The "Decoding CF" section in the side bar allows you to extract birthdate and place of birth from any tax code.
Suggerimenti
- The teaching mode is very useful to understand how the code's algorithm works: shows every step of calculation with input value, applied process and intermediate result.
- To test the validation of a form, use the "Verify Tax Code" section in the sidebar to check immediately if a code is correct before entering it into your system.
- Use "Generate Random" to quickly get realistic test data without manually filling out the form, useful for populating development databases.
Domande frequenti
How is the Italian tax code calculated?
Italian tax code for individuals is composed of 16 characters: 3 consonants (or vowels if insufficient) from the surname, 3 from the first name, 2 digits for birth year, 1 letter for the month (fixed A-T), 2 digits for day (+40 for females), 4 characters from the municipality's land registry code and 1 calculated control character according to DM 12/03/1974.
Are generated tax codes valid for official use?
No. The generated codes are mathematically correct and pass character control validation, but they're fictional. They don't correspond to real people and should not be used for tax, legal, or administrative purposes. They're intended exclusively for testing and software development only.
What are the homophones of the tax code?
The same surname, name, date of birth, and place of birth can generate duplicate names. In this case, the Tax Agency replaces some digits with letters (table: 0=L, 1=M, 2=N, 3=P, 4=Q, 5=R, 6=S, 7=T, 8=U, 9=V). Each person can have up to 128 duplicate names.
Can I calculate your foreign birth certificate code?
Yes. By activating the "Born Abroad" option, you can select your country of birth from the dropdown menu. The generator will use the foreign country's census code (always starting with Z) instead of the Italian municipality, following the same calculation rules.
How does code character control work?
Character control is calculated by summing the values of each character in the code (even and odd positions have different conversion tables), dividing the sum by 26, and converting the remainder to letter (A=0, B=1, ..., Z=25). This allows for error detection.