Updated
How to Validate a SIREN or SIRET Number (Luhn Check, With Code)
The Luhn checksum in 4 steps
- Read the digits from right to left.
- Double every second digit (the 2nd, 4th, 6th from the right).
- When a doubled digit is above 9, subtract 9.
- Add all digits: the number is valid when the total is a multiple of 10.
Example with 552032534 (Danone): the total is 30, so it is valid. Change the last digit to 5 and the total becomes 31: invalid.
A tested Python function
def luhn_ok(number: str) -> bool:
total = 0
for i, ch in enumerate(reversed(number)):
d = int(ch) * (2 if i % 2 else 1)
total += d - 9 if d > 9 else d
return total % 10 == 0
def valid_siren(s: str) -> bool:
s = s.replace(" ", "")
return len(s) == 9 and s.isdigit() and luhn_ok(s)
def valid_siret(s: str) -> bool:
s = s.replace(" ", "")
if len(s) != 14 or not s.isdigit():
return False
if s.startswith("356000000"): # La Poste exception
return True
return luhn_ok(s)Checked on 4 December 2026 with real numbers: 552032534 and 855200887 (SIREN), 55203253400703 and 85520088700039 (head-office SIRET of Danone and Michelin), 35600000000048 (La Poste head office) all pass; 552032535 fails.
From a valid number to a real company
The checksum says nothing about existence or status. The free government API Recherche d'entreprises (recherche-entreprises.api.gouv.fr, no key, about 7 requests per second) returns name, status, activity code and head office for a SIREN or SIRET. Our guide How to check a French company by SIREN or SIRET covers the official sources, the VAT number and insolvency notices.
Checking a whole list
Plainprobe French Company Data validates every SIREN and SIRET before the lookup (invalid numbers come back with the free error code INVALID_INPUT), then returns one clean profile per company from the official open data, for $0.005 per profile, with optional VIES VAT and BODACC checks.
FAQ
How do I check that a SIREN number is valid?
It must have 9 digits and pass the Luhn checksum: from the right, double every second digit, subtract 9 from results above 9, add everything; the total must be a multiple of 10. 552032534 (Danone) passes; 552032535 fails.
How do I check a SIRET number?
It must have 14 digits, start with a valid SIREN and pass the Luhn checksum on all 14 digits. Danone's head office SIRET 55203253400703 passes.
Why does a La Poste SIRET fail the Luhn check?
La Poste (SIREN 356000000) has more establishments than Luhn check digits allow, so many of its SIRET numbers do not pass Luhn. Accept SIRET numbers that start with 356000000 without the Luhn test.
Does a valid checksum mean the company exists?
No. The checksum only catches typos. To know whether the company exists and is active, look it up in the official register (free API Recherche d'entreprises).