For many companies in Poland, KSeF has become a symbol of another regulatory obligation. That is only partly true. In practice, the National e-Invoicing System is also a driver for organizing the entire document flow: from issuing an invoice, through cost approval, to archiving, status monitoring, and reporting for accounting and management.
The quickest answer is: Invoice, Document, and KSeF Automation in Poland
A practical guide to KSeF, OCR, document circulation, ERP integration, approval workflows, compliance, and ROI for invoice automation.
What is KSeF and why does it affect the entire process?
KSeF is an ICT system operated by the Head of the National Revenue Administration, used to issue, send, receive, and store structured invoices. From a company’s perspective, this means moving from documents circulated by email or as PDFs to a model in which an invoice is a data structure.
Invoice automation should not end with sending XML to the tax administration. If the team still manually re-enters data from PDFs, tracks approvals in an email inbox, and reports document status separately, KSeF becomes only another step in the process. Real value appears when KSeF is connected with OCR, validation, document workflow, ERP integration, and reporting.
SmartCodeIT helps companies from Gliwice, Silesia, and across Poland view KSeF not only as a formal requirement, but also as an opportunity to simplify the work of accounting, sales, purchasing, administration, and management.
Current legal status in Poland
As of May 27, 2026, the obligation to issue invoices in KSeF is being introduced in stages. From February 1, 2026, it applies to taxpayers whose sales value, including tax, exceeded PLN 200 million in 2024. From April 1, 2026, it applies to other taxpayers, except for the smallest companies using the limit through the end of 2026.
Until the end of 2026, taxpayers whose total sales value documented by invoices in a given month does not exceed PLN 10,000 gross may still issue invoices outside KSeF. For them, the general obligation to issue invoices in KSeF begins on January 1, 2027.
Receiving invoices through KSeF is mandatory from February 1, 2026, with statutory exclusions. B2C invoices remain optional. The Ministry of Finance also indicates that, in the initial period of mandatory KSeF, penalties for errors related to using the system will apply only from January 1, 2027.
- February 1, 2026: the largest entities, gross sales above PLN 200 million in 2024.
- April 1, 2026: other taxpayers, except for the smallest companies covered by the monthly limit.
- January 1, 2027: taxpayers using the PLN 10,000 gross monthly limit through the end of 2026.
- B2C invoices: optional.
- Penalties for KSeF errors: from January 1, 2027, according to Ministry of Finance communications.
Technical requirements: FA(3), XML, API, and offline modes
FA(3) and XML
In the mandatory model, the FA(3) logical structure is used. This is not a graphical view of an invoice, but an XML data schema published by the Ministry of Finance. The system must correctly populate the required fields, preserve the data format, and handle validation before submission.
KSeF 2.0 API and test environments
The KSeF 2.0 API documentation was published in 2025, and the API test environment was made available on September 30, 2025. Companies with higher document volumes should plan API integration with an ERP, sales system, or document panel, instead of basing daily work on manual file uploads.
Tokens, certificates, and offline modes
The architecture should account for permissions, tokens, KSeF certificates, and offline procedures. A type 2 certificate is required to mark invoices with a QR code in offline modes, and the system should support resend attempts, statuses, UPO, and exceptions.
XML, UBL, and EDI are not the same
In the Polish KSeF, an invoice must ultimately conform to the FA(3) schema. Many companies also use EDI, UBL, or Peppol in parallel, but these usually require data mapping to the national structure. The key question is therefore: can we correctly map the data to FA(3) and detect errors before sending?
How does invoice and document automation work?
A modern process should separate two streams: documents that are already structured and documents that first need to be read and categorized. KSeF works with structured data, while OCR, IDP, workflow, and RPA help process documents that still arrive as PDFs, scans, photos, email attachments, or exports from another system.
The architecture below is a practical model for SMBs, accounting offices, service companies, and trading companies. It does not have to be implemented all at once. The safest approach is to start with one workflow, such as cost invoices or sales invoices.
| Module | Business role | What it should do |
|---|---|---|
| Document intake layer | Data collection | Receive documents from email, customer portals, folders, ERP, CRM, KSeF, and forms. |
| OCR and IDP | Data reading | Extract fields from PDFs, scans, and photos, and classify the document type. |
| Validation | Regulatory compliance | Verification of FA(3) fields, tax IDs, VAT rates, duplicates, missing data, and business logic. |
| Document workflow | Process control | Approvals, account assignments, escalations, SLA, statuses, and exception paths. |
| ERP and CRM integration | Operational consistency | Data transfer to sales, accounting, purchasing, reports, and customer records. |
| KSeF gateway | Technical compliance | API, tokens, certificates, statuses, UPO, retry, offline handling, and failure handling. |
| Archive and BI | Control and audit | Search, change history, KPIs, and reports for the CFO, owner, and accounting team. |
Why does invoice automation make business sense?
The Ministry of Finance identifies benefits such as a lower risk of errors, document circulation close to real time, easier data import into accounting systems, access to invoices for 10 years, and a shorter standard VAT refund period in certain cases.
In practice, the benefits appear when a company automates not only submission to KSeF, but also what happens before and after the invoice: reading, control, approval, reminders, transfer to accounting, archiving, and reporting.
A well-implemented process shortens document approval time, reduces data errors, limits manual retyping, and gives the owner or management team an up-to-date view of statuses.
- less manual retyping of data from invoices and PDFs
- faster detection of missing information, duplicates, and incorrect data
- a clear approval path for cost invoices
- easier reporting of pending and overdue documents
- better control of cash flow and month-end closing
- lower risk of working with outdated email attachments
On-prem or cloud for the invoice process?
The choice between an on-premises and cloud solution depends on the systems, security, document volume, and how the team works. For many small and mid-sized companies, the cloud means a faster start. For organizations with a complex ERP, compliance requirements, and local integrations, a hybrid or on-premises approach may make sense.
| Criterion | On-premises | Cloud |
|---|---|---|
| Project start | Usually slower and requires greater involvement from internal IT. | Usually faster and easier to launch in stages. |
| Environment control | High level of control over infrastructure and local integrations. | Greater dependency on the provider, but simpler maintenance. |
| Scaling remote work | Good, but more often requires in-house administration. | Usually simpler organizationally and faster to scale. |
| Updates | Handled by the company or the implementation partner. | Handled to a greater extent by the service provider. |
| When to choose | When the company has complex internal systems and security requirements. | When fast implementation time and a lower entry cost matter. |
In practice, many implementations combine both models: the ERP remains in the current environment, while OCR, the document panel, monitoring, or dashboard runs in the cloud.
How to implement KSeF and document workflow step by step?
The safest model for small and midsize companies is a phased implementation: first a process audit, then data mapping to FA(3), followed by integration of the ERP or sales system with KSeF, while simultaneously organizing the flow of cost documents through OCR, validation, and approval workflow.
The biggest mistake is reducing the project to only a technical connection. KSeF affects sales, purchasing, accounting, administration, IT, and permission management, so roles, statuses, responsibilities, and contingency scenarios must be designed.
- Do we know all invoice sources?
- Do we have field mapping to FA(3)?
- Is it clear who grants and controls permissions?
- Will the process support offline modes and outages?
- Does validation run before submission to KSeF?
- Do cost documents have an approval workflow?
- Does the system generate logs, statuses, UPO, and an exception register?
- Have users completed tests of day-to-day and emergency scenarios?
- Week 1
Audit of the process, document sources, and KPI selection.
- Week 2
Data mapping to FA(3) and compliance analysis.
- Week 3
Design of the document architecture, permissions, and statuses.
- Week 4
OCR integration and document intake from email, folders, or a panel.
- Week 5
Integration with ERP, CRM, the sales system, and the KSeF API.
- Week 6
Error validation, retry, offline mode, UPO, and exception register.
- Week 7
User testing and routine and emergency scenarios.
- Week 8
Training, production launch, monitoring, and hypercare.
KPI, ROI, and indicative costs
A good KSeF project should not be assessed only by whether the document was sent to the system. Better KPI include the average processing time for a cost invoice, the percentage of documents processed without manual retyping, the number of validation rejections, the time to close the month, the time from invoice receipt to approval, and the number of exceptions handled without involving accounting.
The values below are indicative and should be treated as a starting point for discussion, not as a ready-made quote. Implementation depends on document volume, the current ERP, the number of companies, integrations, security requirements, the scope of OCR, and the support model.
| Item | Indicative cost | Data status |
|---|---|---|
| Comarch KSeF module for ERP Optima | $4–$158 per month depending on the document limit | public vendor price list |
| Comarch KSeF module for ERP XL and Altum | monthly packages depending on the document limit | public vendor price list |
| SAP DRC layer and Poland KSeF process | not publicly specified | implementation quote |
| Process audit and roadmap | $1,318–$3,953 net | indicative model |
| ERP integration with the KSeF API plus validation | $6,588–$21,083 net | indicative model |
| OCR and workflow for cost documents | $5,271–$15,812 net plus OCR service usage | indicative model |
| Document portal for a client or accounting office | $10,542–$31,625 net | indicative model |
Tax and accounting decisions should be confirmed with an accountant or tax advisor. SmartCodeIT designs and implements the technical layer, integrations, automations, panels, and workflows.
Estimate a simple automation payback.
This is an indicative model. A production assessment should also include error risk, customer response time, downtime and maintenance.
How does SmartCodeIT help with implementation?
The most logical cooperation model is a short audit and process workshop, a pilot for one document workflow, KSeF integration with the existing ERP or sales system, implementation of OCR for cost documents and an approval workflow, followed by a KPI dashboard and team training.
This approach is well suited to service companies, trading companies, accounting offices, and e-commerce businesses. The project does not need to start with an expensive revolution. It can start with one document type, one department, or one approval path.
If you want to move from basic KSeF compliance to real invoice automation, OCR, and document workflow, start with a conversation about the process. Only then is it worth selecting the tools.
FAQ
Is KSeF already mandatory?
Yes. As of February 1, 2026, the obligation applied to taxpayers with gross sales above PLN 200 million in 2024, and as of April 1, 2026, to other taxpayers, except for the smallest companies using the PLN 10,000 gross monthly limit through the end of 2026.
Does every small business have to issue invoices in KSeF immediately?
Not always. Through the end of 2026, taxpayers whose monthly sales documented by invoices do not exceed PLN 10,000 gross may still issue invoices outside KSeF. As of January 1, 2027, the obligation also applies to this group.
Do B2C invoices have to be issued in KSeF?
No. Invoices for consumers remain optional. In practice, it is worth separating the B2B, B2G, and B2C processes so the system can correctly handle obligations and exceptions.
Is a PDF sent by email an e-invoice under KSeF?
No. KSeF works with structured XML compliant with the FA(3) schema. A PDF can be a visualization or an input document for OCR, but it does not replace an e-invoice in KSeF.
Can UBL or Peppol be sent directly to KSeF?
As a rule, a mapping layer is needed. KSeF ultimately requires the FA(3) structure, while Peppol and UBL use a different data exchange standard.
Can an ERP be used instead of the free Ministry of Finance application?
Yes. Companies can use commercial financial and accounting software integrated with the KSeF API. Free Ministry of Finance tools are an option, but not the only path.
Does OCR replace KSeF?
No. OCR reads data from PDFs, scans, or photos, while the final submission to KSeF is a valid XML file compliant with FA(3). OCR is a component of document automation, not a substitute for KSeF.
How long are invoices stored in KSeF?
According to information from the Ministry of Finance, structured invoices are stored in KSeF for 10 years, counted from the end of the year in which they were issued.
How does offline mode work in KSeF?
KSeF provides for online operation as well as offline and emergency procedures. Therefore, the implementation system should support retries, invoice marking, later submission of documents, statuses, and an exception register.
Will penalties apply in 2026 for errors when using KSeF?
The Ministry of Finance indicates that financial penalties for errors related to the use of KSeF will apply from January 1, 2027. It is worth using 2026 to refine the process and conduct testing.
When will the KSeF number need to be provided with a payment?
The requirement to provide the KSeF number for certain payments takes effect on January 1, 2027. It is worth preparing the ERP, bank exports, and payment workflow earlier in the process.
Are pro formas, notes, and other supporting documents sent to KSeF?
Not every company document is submitted to KSeF. Pro formas, internal documents, and notes require separate organization within the document process, but they are not classic KSeF structured invoices.
Sources
- Ministry of Finance: KSeF applicability rules and legal regulations
- Ministry of Finance: scope of mandatory KSeF
- Ministry of Finance: KSeF 2.0 implementation stages
- Ministry of Finance: KSeF certificates
- Ministry of Finance: KSeF 2.0 API and FA(3) structure
- Microsoft Learn: Invoice data extraction
- SAP: Document and Reporting Compliance
- SAP Help Portal: Poland KSeF eInvoice process
- UiPath: Invoice Processing with SAP
- Comarch: KSeF integration in ERP systems
Do you want to move from KSeF compliance alone to practical automation of invoices, OCR, and document workflows? SmartCodeIT can start with a process audit, an ERP integration map, and a pilot for one document type.
Schedule a KSeF and OCR consultation