Get in touch
  • WordPress
  • Payments
  • v1.0.1

KSeF E-Invoicing for WooCommerce — FA(3) e-invoices to Poland’s KSeF straight from orders

Structured FA(3) e-invoices for Poland's KSeF from WooCommerce orders: sent directly to the KSeF API 2.0 with your own token, no SaaS subscription. KSeF number and UPO on the order, NIP field at checkout, retry queue, TEST/DEMO/PROD. Pro — correction invoices from refunds, EU and non-EU buyers, B2C, currencies with the NBP rate, KSeF QR code for customers.

Download Free
Pro · one-year licence The more sites, the less each one costs
Compatibility
WooCommerce 8.0+ · WordPress 6.2+ · PHP 7.4+ · HPOS · classic and block checkout · KSeF API 2.0, FA(3)
Licence
one site, annual
Trial
7 days, no card, one per site
Updated
24 September 2026
Or all 144 Pro modules with All Access — 4 990 ₴ / year

What Free has,
and what Pro adds

The free version works with no time limit. Pro adds the rest of the features in the table.

Feature Free Pro
FA(3) invoice (schema 1-0E) built from the order: seller, buyer with NIP, items, shipping, fees, VAT per rate, payment ✔ ✔
Rates 23/22/8/7/5/4/3 %, 0 % KR, zw exemption with legal basis, np, reverse charge (oo); VAT from WooCommerce taxes, a fixed rate included in prices, or a VAT-exempt seller ✔ ✔
Automatic issuing when the order becomes "Completed" or "Processing"; "Issue KSeF invoice" button on the order ✔ ✔
Direct sending to the KSeF API 2.0 with your KSeF token: online session, AES-256 encryption, no third-party service ✔ ✔
KSeF number and the official UPO on the order, XML and UPO download ✔ ✔
NIP field on the classic and block checkout with checksum validation; company name next to it when WooCommerce hides it ✔ ✔
Queue with automatic retries: KSeF down — invoices wait and go later ✔ ✔
Duplicate protection: a lost answer never creates a second invoice, someone else's KSeF number is never attached to an order ✔ ✔
Rejection reasons in KSeF's own words, "Regenerate and send" after a fix, "Discard" ✔ ✔
TEST, DEMO and PRODUCTION environments with separate number counters ✔ ✔
Your own number format: {YYYY}/{MM}/{DD}/{N}, reset monthly, yearly or never ✔ ✔
Invoice register in the admin, "Check the connection to KSeF", token encrypted in the database ✔ ✔
Plugin languages: English, polski ✔ ✔
Correction invoices (KOR) from WooCommerce refunds — by items or by amount, with the original's KSeF number — ✔
Buyers from other EU countries (VAT UE, 0 % WDT) and outside the EU (export, 0 % EX) — ✔
Consumer (B2C) invoices in KSeF when you choose to send them — ✔
EUR, USD and other currencies with the NBP rate and VAT in PLN in the XML — ✔
KSeF number and verification QR code (KOD I) in the customer e-mail, My Account and the printable invoice — ✔
Bulk "Issue KSeF invoice" for past orders, CSV register for your accountant, alerts on rejected invoices — ✔

What it looks like

NIP and company name fields for the invoice on the WooCommerce block checkout
Block checkout: under “Additional order information” — the NIP field and, while WooCommerce hides “Company”, the company name field. A NIP without a company name does not pass: “Company name (for a VAT invoice) is required”.
The NIP is not valid error on the WooCommerce classic checkout
Classic checkout: a NIP with a wrong checksum stops the order — “The NIP is not valid. Check the 10 digits.”
Invoice in KSeF block with QR code and KSeF number on the customer's order in My Account
Pro: in My Account → order the customer sees the “Invoice in KSeF” block — the KOD I QR code, invoice number, KSeF number and a link to the printable invoice.

The trial starts when you ask

A fresh install is the free version, nothing switches on by itself. The “Try Pro for 7 days” button → e-mail → the key right in the window and by e-mail.

One key — one site

Moving the store? Unbind the licence on the old domain and activate it on the new one yourself. If our server is unreachable, Pro keeps working for 14 more days. For studios — keys for 5 or 25 sites, or unlimited.

Technical requirements

  • WooCommerce 8.0+ with the classic or block checkout, HPOS compatible
  • WordPress 6.2+ · PHP 7.4+ with OpenSSL (no third-party libraries)
  • A KSeF token for the seller NIP from the taxpayer application of the environment you work in (TEST, DEMO or PRODUCTION). When moving from TEST to PRODUCTION the token must be replaced.
  • WooCommerce taxes with Polish rates (23 %, 8 %, 5 % …), or the fixed-rate or zw mode. Rates outside the Polish list (for example OSS 19 %) produce no invoice — the plugin explains why.
  • Shop currency — PLN for Free; other currencies with the NBP rate in Pro.
  • Plugin languages: English and Polish.

Version history

v1.0.1 Current 24 September 2026

The Pro version activates next to an active free copy from WordPress.org without PHP warnings and no longer loads its code from the free copy’s folder.

v1.0.0 First release September 2026

FA(3) 1-0E, KSeF API 2.0 with a KSeF token, retry queue, UPO, duplicate protection, NIP and company name fields on the classic and block checkout, TEST/DEMO/PRODUCTION; English and Polish.

Frequently bought with KSeF E-Invoicing for WooCommerce

4 modules in one order — 40% cheaper than separately

“Store starter” bundle KSeF E-Invoicing Nova Poshta Premium LiqPay Telegram notifications and Viber/SMS for customers Need more — all 144 modules in All Access for 4 990 ₴.
3 490 ₴ / year instead of 5 860 UAH bought separately
Buy the bundle →

Full module description

KSeF E-Invoicing for WooCommerce is a plugin for shops in Poland that invoice businesses. Since 2026 Polish VAT payers issue B2B invoices through the National e-Invoice System (Krajowy System e-Faktur, KSeF). The plugin turns a WooCommerce order into a structured invoice in the official FA(3) format and sends it straight to the KSeF API 2.0 — no accounting SaaS in the middle and no monthly subscription. The KSeF number and the official confirmation of receipt (UPO) are saved on the order.

What you need. A KSeF token for your company’s NIP, generated in the KSeF taxpayer application (Aplikacja Podatnika KSeF) of the chosen environment (“Tokeny”, permissions to issue and view invoices). Honestly about testing: the plugin has been tested on the official KSeF TEST environment of the Ministry of Finance — the invoices were accepted with real KSeF numbers and UPOs, and every XML is valid against the official FA(3) XSD. We have not run it on DEMO or PRODUCTION yet: the API is the same, but it needs a real company. Try it on your own NIP in the 7-day Pro trial — if KSeF answers differently than on TEST, we fix it quickly.

The shop remains responsible for the content of its invoices: the plugin builds FA(3) from the WooCommerce order data (rates, addresses, NIP). Tax decisions — when to use 0 % KR, WDT or EX, the cash method, the correction type — follow the schema field descriptions and the Ministry of Finance documentation; show your settings to your accountant before switching to PRODUCTION.

What the customer sees

The checkout gets a “NIP (for a VAT invoice)” field. It is optional: without a NIP the order goes through as usual and no KSeF invoice is created. When a NIP is entered, the plugin checks its checksum — a wrong number stops the order with an explanation. “5265877635”, “526-587-76-35” and “PL5265877635” are all accepted.

WooCommerce 11 hides the “Company” field by default, so the invoice would go out in a person’s name. While the WooCommerce field is hidden, the plugin shows its own “Company name (for a VAT invoice)” field next to the NIP: it is required together with a NIP, and the company name goes on the invoice as the buyer. Switch the “Company” field on in the WooCommerce settings and the plugin uses that one instead.

What the admin gets

  • WooCommerce → KSeF: “Invoices”, “Settings” and “Licence” tabs.
  • The KSeF token is stored encrypted in the database with keys derived from your site’s secret salts; the form shows only its last characters. It can also be defined as CCKSEF_TOKEN in wp-config.php.
  • “Check the connection to KSeF” runs the full authentication and tells you which NIP and environment it works with, or shows the KSeF error in its own words (for example 450 for a wrong token).
  • Environment — TEST, DEMO or PRODUCTION; while TEST or DEMO is on, a reminder at the top says that invoices have no legal effect.
  • Seller (Podmiot1): NIP, name, address, contacts, KRS / REGON / BDO in the invoice footer.
  • Numbering: a format such as FV/{YYYY}/{MM}/{N}, reset monthly, yearly or never, separate counters per environment; numbers already used are skipped.
  • VAT: from WooCommerce taxes, a fixed rate included in prices, or a VAT-exempt seller (zw with the legal basis).
  • Invoice register: number, order, buyer with NIP, total, status, KSeF number or rejection text; status filter and search.
  • “KSeF invoice” box on the order: invoice number, status, KSeF number, QR code, links to details, XML and UPO. Orders without an invoice get an “Issue KSeF invoice” button.
  • Order notes: “created and queued”, “accepted, KSeF number …” or the rejection reason.
  • “Send queued invoices now” sends the queue at once, including invoices waiting for a retry.

A rejected invoice shows up right away: in the register, on the order and in a notice at the top of the admin. Next to it is the KSeF text in Polish, exactly as the Ministry of Finance returned it, and the full FA(3) XML. After a fix (date, buyer data, rate) — “Regenerate and send”; an invoice that never reached KSeF is cancelled with “Discard”.

The number is already taken by another program. If you also issue invoices in another program on the same NIP with the same number pattern, KSeF refuses a second invoice with that number. The plugin compares files by SHA-256 against the original’s UPO: its own file (for example when a KSeF answer was lost) is accepted with its KSeF number, someone else’s never. Such an invoice becomes “Rejected by KSeF” with an explanation and the KSeF number of the other document; change the number format (for example a SKLEP/ prefix) and click “Regenerate and send” — the invoice gets a new number.

How it works — step by step

  1. Setup. WooCommerce → KSeF → Settings: environment, seller NIP and address, KSeF token, “Check the connection to KSeF”.
  2. Checkout. A business buyer enters the NIP (and the company name if the “Company” field is hidden). A wrong NIP does not pass.
  3. Order status. The order becomes “Completed” (or “Processing” — your choice) — the plugin builds the FA(3) invoice with the next number and queues it.
  4. Sending. Action Scheduler opens a KSeF online session right away, encrypts the invoice and sends it; a cron every 5 minutes is the safety net.
  5. KSeF status. The plugin polls KSeF: accepted — the KSeF number lands on the order and the UPO follows a minute or two later; rejected — the reason text appears in the register and on the order.
  6. Outages. KSeF unreachable, 429 or 503 — the invoice waits and retries by itself; the same XML byte for byte, so no second invoice appears.
  7. Refunds (Pro). A WooCommerce refund by items or by amount creates a KOR correction invoice with the original’s KSeF number; it waits until the original has its number.
  8. Customer (Pro). The “Your invoice is in KSeF” e-mail with the KSeF number and the KOD I QR code, a block in My Account and a printable invoice.

Under the hood

  • FA(3), schema 1-0E — element order strictly by the Ministry of Finance XSD; eight document types (B2B with several rates, zw, EU in EUR, B2C, export, KOR with and without a KSeF number, minimal) validate against the official schema.
  • KSeF API 2.0 without third-party libraries: token authentication (RSA-OAEP SHA-256), online session of up to 20 invoices, AES-256-CBC, status polling, UPO. Access and refresh tokens are cached; 401 — re-authentication, 21470 (Ministry key rotation) — the keys are re-read.
  • The XML never changes after it is created. A retry sends the same file byte for byte, so a lost KSeF answer yields 440 with the original number rather than a second invoice.
  • A 440 duplicate is accepted only for the plugin’s own file: SkrotDokumentu from the original’s UPO is compared with the SHA-256 of our XML. If it cannot be compared — retries for up to 24 hours, never “accepted blindly”.
  • Numbering under a lock (MySQL GET_LOCK): two orders in the same second never get the same number.
  • NBP rate (Pro) — table A of the last working day before the sale date; the XML carries KursWaluty and VAT in PLN (P_14_xW).
  • Printable invoice (Pro) — an informational copy: for an invoice in EUR the print does not show the VAT amount in PLN; it is in the XML sent to KSeF.
  • KSeF offline modes (offline24, emergency, KOD II) are not implemented: while KSeF is unavailable, invoices wait in the queue.
  • Deleting the plugin removes the token, the token cache and the cron jobs; the invoice register and counters stay, so numbering continues after a reinstall. The CCKSEF_DELETE_DATA constant removes everything.

Installation

  1. Plugins → Add New → Upload Plugin: choose ksef-e-invoicing-for-woocommerce-1.0.1.zip and activate.
  2. WooCommerce → KSeF → Settings: switch “Issue KSeF invoices” on, choose the environment (start with TEST), fill in the seller NIP, name and address.
  3. Generate a token in the taxpayer application of the same environment, paste it and click “Check the connection to KSeF”.
  4. Check the WooCommerce tax rates and the number format (give the shop its own prefix if another invoicing program is in use).
  5. Place a test order with a NIP and set it to “Completed” — within a minute the order shows a KSeF number.
  6. Moving to PRODUCTION — switch the environment and paste the PRODUCTION token.
  7. For Pro: paste the licence key from the purchase e-mail or start the 7-day trial.

Questions
about the module

Didn't find the answer? Message us on Telegram and we'll reply within a business day.

@catcode_support Setup, compatibility, activation
What do I need to start?

A KSeF token for your company's NIP. You generate it in the KSeF taxpayer application (Aplikacja Podatnika KSeF, "Tokeny") with permissions to issue and view invoices, and paste it into WooCommerce → KSeF → Settings. No separate contract or SaaS account.

What has the plugin been tested on?

On the official KSeF TEST environment of the Polish Ministry of Finance: token authentication, B2B, B2C, EU in EUR and correction invoices, a rejection with its explanation, UPO and duplicates — with real KSeF numbers. It has not been run on DEMO or PRODUCTION yet: the API is the same there, but it needs a real company.

I am moving from TEST to PRODUCTION. What do I change?

The token. A KSeF token works only in the environment it was generated in, so after switching paste a token from the PRODUCTION taxpayer application. Each environment has its own number counters.

I also issue invoices in another program on the same NIP.

Give the shop its own number format, for example SKLEP/{YYYY}/{MM}/{N}. If the other program has already used the same number, KSeF refuses it, and the plugin marks the invoice as rejected with an explanation instead of attaching someone else's KSeF number to the order. After changing the format — "Regenerate and send".

Do consumer orders go to KSeF?

KSeF is mandatory for invoices to businesses, not to consumers. Free sends only orders with a buyer NIP; Pro can send consumer invoices too.

What if KSeF is down?

Invoices stay in the queue and go automatically as soon as KSeF answers. Nothing is lost, nothing is sent twice.

Not quite what you are looking for?

We build custom modules for WordPress, WooCommerce, OpenCart and Shopify. Tell us about the task and we'll prepare an estimate.

Order a custom module