FA(3) field reference

Nagłówek in FA(3): the invoice header

The Nagłówek header of a KSeF FA(3) invoice: KodFormularza, WariantFormularza, DataWytworzeniaFa and SystemInfo, with a valid XML example.

Updated

Overview

Nagłówek (the header) is the first required section of every FA(3) invoice. It identifies the form version and records the exact moment the XML document was generated. It contains four elements: KodFormularza, WariantFormularza, DataWytworzeniaFa and the optional SystemInfo.

The four header fields

KodFormularza is the form symbol and always has the value FA, together with two fixed attributes: kodSystemowy="FA (3)" and wersjaSchemy="1-0E". These are not choices — they must appear exactly as written for the document to validate against the FA(3) schema. WariantFormularza is always 3 in the FA(3) structure; do not change it.

DataWytworzeniaFa is the date and time the invoice was generated, in ISO 8601 timestamp format with a Z suffix for UTC, for example 2026-10-12T07:23:07Z. The XSD constrains it to a window between 1 September 2025 and 1 January 2050. It is not the same as the business issue date P_1, which lives in the Fa section.

SystemInfo is an optional free-text field of up to 256 characters naming the IT system that produced the invoice. Notaly writes "einvoice-api" here.

Why the header matters

The header is what tells KSeF which schema version a document uses. A wrong KodFormularza or wersjaSchemy makes the whole document fail validation before any business data is even read. Because these values are fixed, they are the easiest part of the invoice to get right — and also the easiest to break by hand-editing.

Where it sits in the document

Nagłówek comes before Podmiot1 (the seller) and Podmiot2 (the buyer). It is metadata about the document, not about the transaction; the transaction dates live in the Fa section, with P_1 for the issue date and P_6 for the optional supply date.

A complete, valid FA(3) example appears below with the header filled in.

<Faktura xmlns="http://crd.gov.pl/wzor/2025/06/25/13775/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <Naglowek>
    <KodFormularza kodSystemowy="FA (3)" wersjaSchemy="1-0E">FA</KodFormularza>
    <WariantFormularza>3</WariantFormularza>
    <DataWytworzeniaFa>2026-10-12T07:23:07Z</DataWytworzeniaFa>
    <SystemInfo>einvoice-api</SystemInfo>
  </Naglowek>
  <Podmiot1>
    <DaneIdentyfikacyjne><NIP>2745013933</NIP><Nazwa>Example Sp. z o.o. (FICTIONAL)</Nazwa></DaneIdentyfikacyjne>
    <Adres><KodKraju>PL</KodKraju><AdresL1>ul. Testowa 1, 00-001 Warszawa</AdresL1></Adres>
  </Podmiot1>
  <Podmiot2>
    <DaneIdentyfikacyjne><NIP>1234563218</NIP><Nazwa>Test Customer S.A. (FICTIONAL)</Nazwa></DaneIdentyfikacyjne>
    <Adres><KodKraju>PL</KodKraju><AdresL1>ul. Probna 2, 30-001 Kraków</AdresL1></Adres>
    <JST>2</JST>
    <GV>2</GV>
  </Podmiot2>
  <Fa>
    <KodWaluty>PLN</KodWaluty>
    <P_1>2026-10-12</P_1>
    <P_2>FV/2026/10/001</P_2>
    <P_13_1>1000.00</P_13_1><P_14_1>230.00</P_14_1>
    <P_13_2>301.00</P_13_2><P_14_2>24.08</P_14_2>
    <P_15>1555.08</P_15>
    <Adnotacje>
      <P_16>2</P_16><P_17>2</P_17><P_18>2</P_18><P_18A>2</P_18A>
      <Zwolnienie><P_19N>1</P_19N></Zwolnienie>
      <NoweSrodkiTransportu><P_22N>1</P_22N></NoweSrodkiTransportu>
      <P_23>2</P_23>
      <PMarzy><P_PMarzyN>1</P_PMarzyN></PMarzy>
    </Adnotacje>
    <RodzajFaktury>VAT</RodzajFaktury>
    <FaWiersz>
      <NrWierszaFa>1</NrWierszaFa>
      <P_7>SaaS subscription - October</P_7>
      <P_8A>pcs.</P_8A>
      <P_8B>1</P_8B>
      <P_9A>1000.00</P_9A>
      <P_11>1000.00</P_11>
      <P_12>23</P_12>
    </FaWiersz>
    <FaWiersz>
      <NrWierszaFa>2</NrWierszaFa>
      <P_7>Support</P_7>
      <P_8A>hrs.</P_8A>
      <P_8B>2</P_8B>
      <P_9A>150.50</P_9A>
      <P_11>301.00</P_11>
      <P_12>8</P_12>
    </FaWiersz>
  </Fa>
</Faktura>

Sources

Source: crd.gov.pl

Frequently asked questions

What is the Nagłówek in a FA(3) invoice?

The Nagłówek is the first required section of every FA(3) invoice; it identifies the form version and records when the XML document was generated.

Can I change KodFormularza or WariantFormularza?

No. KodFormularza is always FA with attributes kodSystemowy='FA (3)' and wersjaSchemy='1-0E', and WariantFormularza is always 3.

Is SystemInfo required?

No. SystemInfo is optional and names the IT system that generated the invoice; Notaly writes 'einvoice-api'.

Issue your first KSeF test invoice today

Create a sandbox account: API key in seconds, 3 free test invoices on KSeF TEST, no credit card.