Electronic invoicing
Electronic invoicing in Costa Rica: a practical guide for hotels
If you run a hotel or lodge in Costa Rica, every stay you sell needs an electronic document that Hacienda accepts. The rules are not hard once you see the pieces. Here they are, in the order you meet them.
The system in one paragraph
Since September 1, 2025, every comprobante electrónico follows version 4.4 of Hacienda’s format, and since October 6, 2025 the tax administration runs on TRIBU-CR, which replaced ATV. Each document is an XML file, signed with your company’s own cryptographic key and sent to Hacienda, which answers with a verdict: accepted or rejected. Any taxpayer may issue documents directly with their own key — there is no list of approved intermediaries you have to go through.
It matters more than it used to. Hacienda now uses the documents you issue to prefill your tax declarations, so a missing document is visible in your declaration, not only in an audit.
Factura or tiquete: which one does a hotel issue?
Two documents cover almost every stay you sell.
| Document | Who it is for | What you need from the buyer |
|---|---|---|
| Tiquete electrónico | A guest who is the final consumer: a tourist, a family on holiday | Nothing. A tiquete does not need the buyer’s details |
| Factura electrónica | A business or professional who buys the stay for its own activity | The legal name and ID number (cédula), which Hacienda checks against its register — and an address, if the buyer is based in Costa Rica |
The difference is not cosmetic. A tiquete cannot be used to justify an expense or a tax credit, so a company that receives one cannot deduct the stay or claim the IVA. When a guest asks for a factura for their company, ask for the cédula before you issue the document, not after.
Two more points catch hotels out. Lodging carries 13% IVA, also when the guest is a foreigner: a stay in Costa Rica is not an export. And a foreign company without a Costa Rican ID number cannot receive a factura for a stay — Hacienda rejects it. It gets a tiquete with its name on it instead.
Bookings from channels
When a guest books through a channel that charges you a commission, the guest’s document is for the full price of the stay. The commission is not a discount on that document: the channel invoices it to you separately.
Notas de crédito: how a document is corrected
A document that Hacienda has accepted cannot be deleted or edited. Every correction is a new document: a nota de crédito to reduce or cancel an amount, or a nota de débito to increase one.
- A nota de crédito always points to the original by its clave — the document’s 50-character number.
- It has to match the original: the same buyer, the same CABYS code, the same exchange rate. And the credits against one document can never add up to more than the document itself.
- A guest cancels and gets everything back: a nota de crédito that cancels the tiquete. A partial refund: a nota de crédito for the part you return.
- A document Hacienda rejected gets no nota de crédito. It has no tax effect: you fix the mistake and issue a new document that replaces it.
- A guest got a tiquete and later needs a factura for their company: the tiquete is cancelled with a nota de crédito, and a factura is issued that says which document it replaces.
The cryptographic key and the PIN
To sign documents, your company needs a llave criptográfica: a .p12 file you generate yourself in Hacienda’s Oficina Virtual (OVi), inside Tico Factura. For a company, only the legal representative can do it, with their own sign-in. It is the one part of electronic invoicing nobody can do for you — not your accountant, and not your software provider.
- The PIN. Keys generated since July 28, 2026 need a PIN of 14 characters, not 4. Write it down somewhere you will still have it in three years: it cannot be recovered, only replaced with a new key.
- The API user. When you create the user in Tico Factura and choose “No, voy a utilizar otro programa”, Hacienda gives you a username and password for your software. They are not your OVi password.
- Treat it like your bank password. Anyone holding the .p12 file and its PIN can issue tax documents in your company’s name.
- Keys expire. When yours does, or when you replace it, you generate a new one and give it to your invoicing software again.
Our step-by-step guide to the Hacienda key walks through the nine screens in TRIBU-CR, in order.
Why documents get rejected
Hacienda first answers that it has received a document. That is not an acceptance: the verdict comes afterwards. A document only counts once it is accepted, so check the verdict, not just that it was sent.
Common causes of a rejection, or of a number you can never use again:
- A numbering that collides. Each document type has its own consecutive numbering, and Hacienda checks the sequence. Coming from another system, your new one has to continue from the last number you issued there. A guessed number can collide with one already used, and that cannot be undone.
- A buyer Hacienda does not know. The ID number on a factura has to exist in Hacienda’s registers. One wrong digit in the cédula is a rejection.
- A factura to a foreign company without a Costa Rican ID number. Issue a tiquete with its name instead.
- A nota de crédito that does not match its original: another exchange rate, another CABYS code, or more than the original amount.
- An activity code that is not in Hacienda’s register for the company issuing or receiving the document.
Issue from the booking, not from a spreadsheet
Most of the mistakes above happen when someone types again what already exists: the guest’s name, the nights, the amount, the exchange rate. The safest invoicing starts from the booking itself.
In Staywarden, invoicing is part of the Complete plan. The tiquete electrónico 4.4 for each stay is built from the booking — the guest, the nights, the amount and the IVA — signed with your own key and filed with Hacienda in one tap, or a whole month at once. Staywarden fetches Hacienda’s verdict separately, so you see accepted or rejected, not just sent.
Setting it up takes your key, its PIN and the API user. Your company details are filled in from Hacienda’s own register, and nothing is issued until you confirm the number of the last document you issued before — even if the answer is “none”. Your accountant can upload the key from a link, without your sign-in. What Complete costs is on the pricing page.
One last thing: this article explains the rules as Hacienda publishes them. For your own company’s case, your accountant has the final word.