Skip to content

How to connect KSeF and fetch purchase invoices

Accounting and finance. Content verified: 12 October 2026.

Before you start

  • In Settings, "Company" tab, fill in the company's NIP and address. Without them, the "KSeF" tab will show the warning "Company details missing".
  • You generate the KSeF token in the Ministry of Finance KSeF application, after logging in with the company's NIP.
  • KSeF can be configured by a person with permission to write company data: Owner, Administrator, Accountant or Accounting firm.

Saving the token

  1. Go to Settings, "KSeF" tab, "Configure KSeF" card.
  2. Leave "KSeF environment" set to Test (test).
  3. Paste the "KSeF token" (at least 10 characters) and click "Save token".

The token is stored in encrypted form, does not appear in the audit log and is never displayed again. To change it, save a new one.

Verifying the connection

The "Verify connection" button logs in to KSeF with the token and the company's NIP, without sending anything. Success is "Connection works"; in case of an error, the message will indicate the cause, e.g. a missing NIP or an invalid token.

Fetching purchase invoices

  • Manually: the "Purchase invoices from KSeF" tab, the optional "Fetch from date" field and the "Fetch purchase invoices from KSeF" button. Requires finance write permission.
  • By default, fetching continues from the last time; the first time it covers the last 30 days.
  • The result is the number of imported invoices, duplicates and errors. Invoices that are already in the system are skipped.
  • Automatically: the AI team fetches invoices in the background, hourly, for companies with a saved token.

Imported invoices go to account assignment and to the approval queue. They are not posted without your decision, unless you deliberately enable automatic mode for posting purchase invoices.