FA(3) field reference

P_8A in FA(3): the unit of measure

How to fill P_8A (the unit of measure) on each FaWiersz of a KSeF FA(3) invoice: optional, format and a valid XML example.

Updated

Overview

P_8A is the unit of measure for a line item (in Polish, "miara"). It sits inside each FaWiersz block and describes what one unit of the quantity in P_8B means — pieces, hours, kilograms, a flat fee, and so on.

P_8A is optional. Many invoices leave it out entirely and are perfectly valid, because the XSD does not require a unit label. When you do include it, keep it short and unambiguous: "pcs.", "hrs.", "kg", "m2", or "month" all work. The value is a text field (TZnakowy), so there is no predefined list of units to conform to.

The reason P_8A exists is readability and auditability. If a line says quantity 2 and unit net price 150.50, the buyer cannot tell whether they paid for 2 hours, 2 days, or 2 units of something. Adding "hrs." turns an ambiguous number into a clear billing statement. For a SaaS invoice, "pcs." or "month" is usually the right label; for services billed hourly, "hrs." is the natural choice.

P_8A does not participate in any arithmetic. The invoice totals are computed from P_8B (quantity) and P_9A (unit net price), and the VAT from P_12. A wrong or missing P_8A therefore cannot change the amount due — it only changes how easily the line can be understood. That said, keep P_8A consistent within an invoice: mixing "hrs." and "hours" on different lines is sloppy and confuses reconciliation.

In Notaly you send the unit as the unit property of a line item, and Notaly maps it to P_8A. If you omit unit, the generated XML simply has no P_8A on that line, which is valid. The API does not reject a missing unit because it is not a required field.

A complete, valid FA(3) example appears below, with P_8A filled on both lines.

<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

Is P_8A required?

No. P_8A (the unit of measure) is optional; when present it must be a short text label such as pcs., hrs. or kg.

Does P_8A affect the VAT calculation?

No. P_8A is descriptive only; the calculation uses P_8B (quantity) and P_9A (unit net price).

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.