Compliance · · 6 min read

What Is an SDI Code? The Codice Destinatario Explained

An SDI code is the Codice Destinatario that tells Italy's exchange system where to deliver an invoice: seven characters, 0000000, XXXXXXX, and how to find one.

An SDI code is the seven-character recipient code in an Italian electronic invoice, known in Italian as the Codice Destinatario, and it tells the Sistema di Interscambio (SdI), Italy's invoice exchange system, where to deliver the file. It identifies a receiving channel, not a company. A business that takes its invoices through an accounting provider has a code that belongs to that channel. A business that reads them by certified email uses the default 0000000 and gives the email address instead.

This page is for the finance or receivables lead who has been asked for "the SDI code" by an Italian customer, or who has found an empty field in an invoicing template. It explains what the code is, the four forms it takes, which one a customer outside Italy gets and where a code comes from. It reads the Agency's specification and FAQ on 31 October 2026. The file the code sits in is described in FatturaPA XML Format.

The four forms of the Italian recipient code. Six characters, an office code for a public administration. Seven characters, a code issued by SdI to a recipient with an accredited channel. Seven zeros, for a recipient using certified email, or an unknown channel. Seven capital X, for a customer not resident, established or identified in Italy.
Which one applies depends on who receives the invoice.

What does the code do?

It decides whether an invoice arrives. Italian invoices do not go from seller to buyer. They go to SdI, which validates the file and passes it on. To pass it on, SdI needs a destination, and the destination is the CodiceDestinatario element in the header's transmission data. The Agency's specification, version 1.4, describes the element as the identifier of the subject to which the invoice is addressed.

The schema accepts six or seven capital letters and digits in the field ([A-Z0-9]{6,7}). The format code in the same header decides which length is valid. A file marked FPA12, for a public administration, needs six characters. A file marked FPR12, for private recipients, needs seven. The wrong length is rejected with error 00427.

What forms does the code take?

Four, and each means something different. The specification lists them.

Value Length Meaning
An office code, such as one from the public index 6 The recipient is a public administration. The code is the "Codice Ufficio" shown on IndicePA, the public index of administrations.
A code issued by SdI 7 The recipient has an accredited receiving channel and asked SdI for a code. The Agency's FAQ calls this the 7-character recipient code and says it can be used only for invoices to private parties.
0000000 7 The recipient takes invoices by certified email, and the address is in PECDestinatario. Or the sender does not know the recipient's channel.
XXXXXXX 7 The invoice is to a customer who is not resident, established or identified in Italy.

Two details are easy to miss. The certified email field, PECDestinatario, may be filled only when the code is 0000000. And the public-administration code is checked against the public index: SdI confirms that the code exists and that its electronic invoicing service has started. A code that fails these checks is rejected with 00311 (not valid) or 00312 (not active).

What is PEC, and when is it used?

PEC, posta elettronica certificata, is Italy's certified email, and it is the fallback. The Agency's FAQ states it plainly: a subject that wants to receive invoices through the PEC channel uses the standard recipient code 0000000, provided the receiving PEC address is given in the invoice's PECDestinatario field.

So an invoice to a small business with no accounting software of its own usually reads:

  • recipient code 0000000, and
  • the customer's PEC address in PECDestinatario.

The same 0000000 is also what a sender uses when it does not know the recipient's channel at all. In that case the file still reaches SdI and still passes the format checks. Whether a particular customer ever sees it is a matter of how that customer is set up. Ask for the real code or the PEC address before the first invoice, not after.

What code does a customer outside Italy get?

XXXXXXX, when the seller is Italian. The Agency's specification gives the case in one line: the value is for an invoice issued to subjects who are not resident, not established and not identified in Italy, and sent to SdI to transmit the data of those invoices. On our reading, SdI delivers nothing to the customer in that case: the file is how the Italian seller reports the sale. The specification does not say so in as many words.

That is a different situation from the one most readers of this page are in. If you are a supplier outside Italy invoicing an Italian customer, the customer's own code is what matters, and whether you issue through SdI at all depends on your position, as the companion page Invoicing an Italian Customer From Outside Italy sets out. SdI also rejects a file in which seller and buyer both carry a non-Italian country code (error 00476), so a XXXXXXX invoice is always the case of an Italian seller with a foreign buyer.

Where do you find a customer's code?

Ask the customer. The code is not derived from anything you already hold, such as the name, the address or the VAT number. We found no public list of business codes in the Agency's documents, and this page does not describe one.

  • A business. Ask for the Codice Destinatario, or the PEC address if it uses PEC. Put the question in onboarding with the VAT number, and confirm it when the customer changes software.
  • A public administration. Look up the six-character office code on IndicePA at indicepa.gov.it. The Agency's documents name it as the source.

Keep the code in the customer record next to the tax identifiers. A customer that moves to another accounting provider changes channel, and nothing in your system will notice.

Can a business have a code of its own?

Yes, if it has an accredited channel. The Agency's FAQ explains that the seven-character code can be requested only by holders of a transmission channel already accredited with SdI for receiving invoices, that it is requested through a function on the Agency's SdI site, and that up to 100 codes can be requested. The FAQ was written for the rules that started on 1 January 2017, and we have read only that text, not a current version of the service. Anyone without such a channel uses 0000000 and a PEC address.

What is still open?

Three things, as of 31 October 2026.

  • How a code is looked up in practice. The Agency's documents we read say where a public body's code is published and that a business gives its own. They do not describe a lookup for businesses.
  • Whether the Agency's FAQ on requesting codes is current. The page we read dates from the 2017 change.
  • What happens to a 0000000 invoice whose channel is unknown. The specification allows it. How often it is delivered is not stated.

What to do next

  1. Ask each Italian customer for a Codice Destinatario or a PEC address, and store it with the VAT number.
  2. Check the length against the format code in your templates: six characters for FPA12, seven for FPR12.
  3. Use XXXXXXX only for an Italian seller's invoice to a customer outside Italy.
  4. Read the file structure in FatturaPA XML Format and the document codes in FatturaPA Document Types: The TD Codes.
  5. To talk through e-invoicing across several countries, book a demo. The developer documentation, the tutorials and the GoRoute API show how documents are sent.

Sources, all read on 31 October 2026: Agenzia delle Entrate, specification of the FatturaPA format version 1.4 (31 January 2025), section 1.1 on transmission data, and schema 1.2.3; the Agency's SdI FAQ on B2B electronic invoices; the Sistema di Interscambio technical specification version 1.8.4 and the list of checks version 2.0, on fatturapa.gov.it. IndicePA is the public index of administrations at indicepa.gov.it. Translations from the Italian are ours.

Frequently asked questions

What is an SDI code?
It is the recipient code in an Italian electronic invoice, called the Codice Destinatario. It tells the Sistema di Interscambio, Italy's invoice exchange system, which channel to deliver the file to. For a private recipient it has seven characters. For a public administration it has six.
What does 0000000 mean?
Seven zeros means the recipient takes invoices by certified email (PEC) and the address is in the PECDestinatario field, or that the sender does not know the recipient's channel. The PEC field may be filled only when the code is 0000000.
What code do I use for a customer outside Italy?
XXXXXXX, seven capital X, for an invoice to a customer who is not resident, established or identified in Italy, sent to SdI so that the data of the invoice can be transmitted. This is the instruction in the Agency's specification. It applies when the seller is Italian.
Where do I find my customer's SDI code?
From the customer. We found no public list of business codes in the Agency's documents. A public administration's six-character code is on the public index of administrations, IndicePA, at indicepa.gov.it.
Can I get an SDI code of my own?
The Agency's FAQ says a seven-character code can be requested by holders of a transmission channel already accredited with SdI to receive invoices, and that more than one code can be requested, up to 100. Someone without an accredited channel uses 0000000 and a PEC address instead.

Related posts

Building on Peppol?

GoRoute is a certified Peppol Access Point & SMP. Book a demo or read the docs to get started.

Book a demo Read the docs