SIREN vs SIRET vs NIF — Which Identifier to Use?

A practical guide to the French and Spanish company identifiers, and which one you should store as your foreign key. Getting this wrong breaks integrations later, usually by creating duplicate rows.

The three identifiers

  • SIREN (France) — 9 digits assigned by INSEE at incorporation. Identifies the legal entity and is stable for life: it never changes even when the company renames, moves, or converts from SARL to SAS. This is the correct foreign key for France.
  • SIRET (France) — 14 digits: the 9-digit SIREN plus a 5-digit NIC (Numéro Interne de Classement). Identifies one physical establishment. A chain has many SIRETs under a single SIREN; NIC 00001 is typically the headquarters. Store SIRET only for per-establishment granularity.
  • NIF (Spain) — one letter encoding legal form (A = SA, B = SL/SRL, F = cooperativa, G = asociación, X/Y/Z = NIE for foreign individuals) plus 8 characters. Issued by the Agencia Tributaria, stable for life. Spain has no SIRET equivalent — companies are identified at entity level only.

Which to store, and common mistakes

France: always SIREN. Spain: NIF. Pan-European: a compound key of country plus local identifier. The guide warns against using VAT as a primary key (VAT can change), storing SIRET when you meant SIREN, treating an NIE as a company NIF, and skipping the check-character validation.

The Prometiam API accepts these directly — search by ?siren=, ?siret=, or ?nif=, or fuzzy by name scoped to a country.

Read more · Get a free API key

TL;DR

Identifier Country Length What it identifies
SIREN France 9 digits Legal entity (company)
SIRET France 14 digits Establishment (office / branch)
NIF Spain 1 letter + 8 chars Legal entity (company or person)
VAT EU-wide FR+11 / ES+9+1 / … EU intra-community VAT

Frequently asked questions

What is a SIREN number?
A SIREN is a 9-digit number that uniquely identifies a French legal entity (company, association, sole trader) across its entire lifetime. Issued by INSEE at incorporation, it never changes — even if the company changes name, address, or legal form.
What is a SIRET number?
A SIRET is a 14-digit number identifying a specific establishment (office, shop, warehouse) of a French entity. Format: 9-digit SIREN + 5-digit NIC (Numéro Interne de Classement). A company with one office has one SIRET; a chain with 50 stores has 50 SIRETs sharing the same SIREN.
What is a NIF in Spain?
The NIF (Número de Identificación Fiscal) is Spain's tax-identification number. For companies it is a letter + 8 characters (e.g., A28015865 for a SA — Sociedad Anónima). The first letter encodes legal form: A = SA, B = SL/SRL, F = cooperativa, G = asociación. For individuals the NIF matches the DNI (national ID) or a NIE for foreigners.
Which identifier should I store?
Store the SIREN (France) or NIF (Spain) as your foreign key — they uniquely identify the legal entity and never change. Store SIRET only if you need per-establishment granularity (e.g., shipping addresses, branch-level billing). Most B2B use cases only need SIREN/NIF.
Can I convert between SIREN and SIRET?
A SIRET always starts with its parent SIREN. To extract SIREN from SIRET: take the first 9 digits. To go the other way, you need to know which establishment — the NIC (5-digit suffix) indicates order of registration, with 00001 typically being the headquarters. Multiple SIRETs per SIREN are normal for larger companies.