E-Invoicing in Costa Rica: Requirements and XML 4.4
Author
Shuaa
-2.webp%3F2026-10-20T10%3A46%3A43.100Z&w=3840&q=100)
E-invoicing in Costa Rica is mandatory for covered businesses and professionals, subject to specific exemptions. The framework covers applicable B2B, B2C, B2G and cross-border transactions and is administered by the Ministry of Finance (Ministerio de Hacienda) and its General Directorate of Taxation (DGT) under the electronic invoicing regulations.
Since September 1, 2025, covered taxpayers must use XML 4.4 for electronic tax documents, following Hacienda’s technical specifications. Documents must contain the prescribed identification, transaction and tax information, be electronically signed using an authorized mechanism and be transmitted to Hacienda for validation.
Latest News
Embeds a monitoring pages group for this blog article
{{__MONITORING_PAGES_GROUP:blog_articles_580__}}On 22 April 2026, Costa Rica’s Hacienda updated the XML 4.4 technical specifications to clarify identification fields, returned-VAT information and document-reference rules.
The update adds new reference and document-type codes for accounting-period adjustments, rejected documents, payment applications and export invoices; Hacienda’s official update notice confirms the codes are available in testing and production, may be used early.
Who Must Use E-Invoicing in Costa Rica?
E-invoicing enables structured electronic invoice exchange; Costa Rica implements it through its comprobantes electrónicos framework, using XML documents under DGT’s technical specifications.
The established system supports fiscal oversight and electronic recordkeeping. XML is the structured tax document; graphical representations, including PDFs, cannot independently substantiate tax credits or deductible expenses
Businesses may use invoicing systems that meet the regulatory requirements, rather than one exclusive government platform.
The Evolution of E-Invoicing in Costa Rica
Costa Rica’s electronic invoicing framework has developed through successive technical and regulatory updates:
- 2016: Resolution DGT-R-48-2016 introduced the 50-digit key and acceptance/rejection message structures. These changes appear in the technical annexes’ historical log on page 13.
- 2019: XML 4.3 introduced purchase and export invoice types, effective July 1, 2019. See pages 10–12 of the historical log.
- 2024: Decree 44739-H updated the electronic-document regulatory framework, establishing requirements for issuance, validation, corrections and recordkeeping.
- September 1, 2025: XML 4.4 became mandatory, as stated on page 3 of Hacienda’s technical annexes.
- April 22, 2026: Hacienda revised the XML 4.4 technical annexes, updating identification-field descriptions, returned-VAT guidance and reference codes. See the adjustment log on page 3.
- November 1, 2026: The newly introduced reference codes become compulsory, with earlier implementation permitted. This is an update within XML 4.4, not a new e-invoicing mandate.
B2G Electronic Invoicing
Covered suppliers must issue compliant electronic invoices for government sales. Under Article 8(1), specified public bodies must generally receive and confirm documents even where exempt from issuing them. VAT-taxable activities trigger issuer obligations.
Both B2G and B2C electronic documents require a 50-digit numerical key, also used for QR-code consultation. This applies to documents within the electronic invoicing framework, not transactions legally exempt from it.
E-invoicing can reduce manual processing and improve traceability. For prescribed deferred-payment arrangements, including applicable government-service transactions, electronic payment receipts document payment without replacing the original invoice.
B2B Electronic Invoicing
Covered business sales require electronic invoices (facturas electrónicas) under Decree 44739-H. Exemptions include qualifying simplified-regime taxpayers and taxpayers registered in the Special Agricultural Regime who exclusively undertake agricultural activities. Scope depends on taxpayer status, regime and activity, not a universal turnover threshold.
B2B, B2C and B2G electronic documents must include the 50-digit numerical key prescribed by Hacienda, also used for QR-code consultation. The applicable document type varies by transaction and recipient, but the key remains required for documents within the electronic invoicing framework. This does not remove legal exemptions from electronic invoicing.
B2C Electronic Tickets
Covered consumer sales use electronic tickets (tiquetes electrónicos), generated and transmitted as XML. Consumers receive a printed graphical representation, but tickets cannot substantiate tax credits or deductible expenses. Purchases requiring that support need the appropriate electronic invoice.
Costa Rica Electronic Invoice Requirements
Compliant documents must include, as applicable:
- A unique 50-digit identification key (clave) and consecutive number.
- Issuer and recipient identification, issue date and transaction details.
- CAByS goods-and-services classification codes.
- Currency, totals, VAT rates, tax amounts and exemption information.
- An authorized electronic signature or security mechanism, such as a digital signature or Hacienda cryptographic key.
Signed XML is transmitted through Hacienda’s API, described in Annex 3 of the technical specifications. Hacienda checks the document and returns an acceptance or rejection response. Under Article 11 of Resolution MH-DGT-RES-0027-2024, Hacienda has up to three hours from receipt of the XML to validate it and return its response. Issuance, transmission and validation are distinct steps; the framework should not be described as universally requiring immediate clearance before every invoice is issued.
Recipients must submit total acceptance, partial acceptance or rejection where documents support VAT credits or deductible expenses. These recipient confirmations are separate from Hacienda’s validation response.
Accepted documents cannot be deleted or directly cancelled. Under Article 10 of Decree 44739-H, electronic credit or debit notes adjust their accounting effects while preserving the original document.
E-Reporting and VAT Compliance in Costa Rica
Invoice-level reporting does not replace monthly VAT returns. Businesses should reconcile sales, purchases, recipient confirmations and adjustment notes with their applicable VAT declarations.
Alongside invoices and tickets, the electronic invoicing regulations recognize:
- Export invoices: For qualifying exports of goods, services and intangibles.
- Purchase invoices: Buyer-issued documents for qualifying purchases from foreign or non-obligated suppliers, subject to statutory exclusions.
- Payment receipts: For prescribed deferred-payment transactions.
- Credit and debit notes: For adjustments to previously issued documents.
- Recipient messages: For acceptance, partial acceptance or rejection.
Electronic documents and Hacienda responses must generally be retained for five years, subject to applicable limitation-period requirements.
What Happens If Businesses Don’t Comply?
Non-compliant documentation can jeopardise VAT credits and expense deductions. Under Article 10, an XML rejected by Hacienda lacks tax validity, so businesses must not issue a credit or debit note against it for tax purposes. Correct the errors and issue a compliant replacement using the applicable reference procedure for rejected documents.
During system or internet failures, follow Hacienda’s contingency procedures, using permitted provisional documents where applicable and subsequently replacing them with electronic documents. Distinguish an inability to issue documents from an outage affecting Hacienda’s validation service.
Your Trusted Partner for E-Invoicing in Costa Rica
Build a stronger foundation for e-invoicing in Costa Rica with DDD Invoices. Connect your ERP, accounting, and billing workflows as part of a scalable international invoicing strategy, with Costa Rica implementation requirements assessed before deployment.
Prioritize XML 4.4 compatibility, accurate tax data, authorized signature mechanisms, Hacienda API connectivity, validation-response handling and secure archiving. Discuss your transaction types, integration needs and country coverage with DDD Invoices to define the right implementation scope.
Displays a content card with title, subtitle, list/body, and action button
{{__CTA:GenericCtaJson:{"type":"content","contentCta":{"layout":"cardList","title":"Talk to us!","subtitleHtml":"Still have questions?","button":{"href":"https://calendly.com/ddd-invoices/30min-intro","label":"Book a free 30min call","color":"white"},"bodyHtml":"In the <strong>30min free call</strong> we will discuss:","listHtml":"<ul><li><strong>your requirements</strong> in invoicing</li><li>how integration works</li><li><strong>demo</strong> of the product</li><li>next steps</li></ul>"}}__}}FAQs
Is e-invoicing mandatory in Costa Rica?
Yes. E-invoicing is mandatory for covered businesses and professionals, subject to specific exemptions based on taxpayer status, regime and activity. See Articles 3, 7 and 8.
What is Costa Rica XML 4.4?
XML 4.4 is Hacienda’s required format for electronic tax documents, mandatory since September 1, 2025. Additional reference codes become compulsory on November 1, 2026.
Is Tico Factura Costa Rica the only permitted solution?
No. Businesses may use Tico Factura or other systems meeting the applicable technical and regulatory requirements. Articles 4 and 5 establish requirements for taxpayer systems and third-party providers.
Can an accepted electronic invoice be cancelled directly?
No. Article 10 requires electronic credit or debit notes to adjust its accounting effects while preserving the original. Rejected documents follow a separate correction and replacement procedure.