E-invoicing (ZATCA)
In Saudi Arabia, every tax invoice must follow ZATCA's e-invoicing rules. In Phase 1 Fiscal prints the ZATCA QR code on your invoices. In Phase 2 it also sends every invoice and credit note to ZATCA: business (B2B) invoices are cleared before they reach the buyer, and simplified (B2C) ones are reported.
Open Settings›eInvoice Setup.
Choose your e-invoicing regime
| Option | When to use it |
|---|---|
| None — not required for this country | Your company is not in a country with e-invoicing rules. |
| Saudi Arabia — ZATCA Phase 1 (Generation) | For companies registered for VAT in Saudi Arabia that are not yet in a Phase 2 wave. Fiscal puts the ZATCA QR code on each invoice and credit note. Nothing is sent to ZATCA. |
| Saudi Arabia — ZATCA Phase 2 (Integration) | For companies ZATCA has called into Phase 2. Every invoice and credit note is signed and sent to ZATCA through the Exler EGS gateway. Your device must be onboarded first (see below). |
| UAE — Peppol e-invoicing (through an ASP) | For companies in the UAE. Business (B2B) invoices and their credit notes are sent as UAE e-invoices (PINT AE) through an Accredited Service Provider on the Peppol network, which also reports them to the FTA (see Set up UAE e-invoicing). |
Set up UAE e-invoicing
In the UAE, e-invoices travel through an Accredited Service Provider (ASP). You can use Exler's e-invoicing service, or an ASP you have your own agreement with.
- Choose UAE — Peppol e-invoicing (through an ASP).
- Under E-Invoicing Service Provider (ASP), choose the Service Provider:
- Exler: Exler sets up your e-invoicing for you and gives you a connection key for your company. Paste it in Connection Key. Once your account is active, the screen shows ACTIVE with your TRN, and invoices are sent automatically. Once saved, the key isn't shown again: leave the box blank to keep it. If Exler gives you a new key, the old one stops working, so enter the new one.
- Your own ASP: choose the Environment (Sandbox (test) or Production) and enter the API Client ID and API Client Secret from your agreement. Once saved, the secret isn't shown again: leave it blank to keep it. The provider's answers are shown to you as they are.
- Set the Start Date: only documents dated on or after it are sent. Leave it empty to send every document.
- Click Test Connection. It tests the values on the screen, so you can check them before saving. When it shows Connected, click Save.
Before you start, get these ready:
- Business customers: their 15-digit TRN and address (see Customers).
- Regions: each region's emirate code.
- Units: an e-invoice unit code for each unit (see Units).
- 0% taxes: a UAE tax category on every 0% tax template (see Tax templates (VAT)).
How it works:
- B2B invoices and their credit notes are sent when they are posted. B2C sales are not sent.
- The result shows under the buttons in the invoice or credit note center. Fiscal checks the provider for the answer automatically.
- Documents not delivered yet are listed in Sales›E-Invoice Queue, where you can send them again.
- A sent document can't be edited or cancelled. Correct it with a credit note (see Credit notes). When you pick an item on the credit note, its unit, rate, discount and tax are filled from the invoice. The Reason you type is sent with the credit note.
- If the customer isn't registered for e-invoicing yet, the document shows Waiting for customer. It is valid and Fiscal sends it again once a day. When you have the customer's Peppol ID, enter it on the customer and click Resend to send it at once.
Supplier e-invoices
E-invoices your suppliers send you arrive in Purchases›Received E-Invoices. Fiscal collects them every hour; click Fetch Now to collect them at once.
- Click an e-invoice to see the supplier, its TRN, the lines, VAT and totals. Supplier's PDF opens the supplier's own copy.
- Choose the Vendor. If none has the supplier's TRN yet, click Create Vendor: the vendor form opens with the name and VAT number filled in.
- Check Our item on each line. Fiscal matches the supplier's item code to your items and remembers each choice for that vendor.
- Click Create Bill. A bill opens with the vendor, the supplier's invoice number, date, due date and lines filled in. Check it and save it. The e-invoice then shows Converted.
An e-invoice you don't need, for example a duplicate, can be set aside with Ignore and an optional reason.
Set up Phase 2
Phase 2 goes through Exler EGS, the gateway that signs your invoices with your company's ZATCA certificate and sends them to ZATCA. Exler IT Hub support onboards your company's device with ZATCA (you will need an OTP from the Fatoora portal), and then gives you the values below.
- Choose Saudi Arabia — ZATCA Phase 2 (Integration).
- Set the Phase 2 Start Date: the date your company starts Phase 2. Only documents dated on or after it are sent to ZATCA (see Documents dated before the Phase 2 start date). Leave it empty to send every document.
- Choose the ZATCA Environment the device was onboarded in: Simulation (ZATCA's test platform, for trying things out) or Production. It is the
Modein the device'sZatcaSetup.json. While it is Simulation, a ZATCA SIMULATION chip shows in the top bar and accepted documents say (simulation): they are not real tax invoices. When the device is onboarded again for production, change it here too. - Leave the Gateway URL as it is (
https://egs.exlerithub.com/) unless support tells you otherwise. - Enter the EGS Client UID, the EGS Device UID, the Computer Unique ID (from onboarding) and the Device Key. Once saved, the device key isn't shown again: leave it blank to keep it.
- Click Save, then Test Connection. The test uses the saved settings and tells you whether the gateway accepted this company's client, device, onboarding id and VAT number. Nothing is sent to ZATCA.
Before you switch on Phase 2
Fiscal checks every document before posting it, so that nothing ZATCA would refuse is posted. Get these ready first:
- 0% taxes: every 0% tax template needs a ZATCA Exemption Code, the reason the line is exempt, zero-rated or out of scope (see Tax templates).
- Business customers: B2B customers need a valid Saudi VAT number (15 digits, starting and ending with 3) and a full national address: street name, building number, district, city and a 5-digit postal code (see Customers).
- Round-off: ZATCA doesn't accept a round-off amount, so clear the round-off on documents, or turn round-off off in Preferences. POS cash rounding is switched off automatically.
- Foreign currency: an invoice in another currency needs its exchange rate to SAR.
- Advance adjustments on an invoice, and export invoices to B2B customers outside Saudi Arabia, can't be sent to ZATCA yet. Invoice a foreign business customer as B2C.
B2B and B2C invoices
| B2B: standard tax invoice | B2C: simplified tax invoice | |
|---|---|---|
| For | Businesses with a Saudi VAT number | Consumers, walk-in customers and all POS sales |
| ZATCA | Cleared: ZATCA checks and stamps it before it is valid | Reported: sent to ZATCA after it is issued |
| Printing | Only once ZATCA has cleared it | Straight away |
| QR code | The one in ZATCA's cleared invoice | Made by Fiscal |
Which one a document is:
- On the customer, E-Invoice Type is Decide by VAT number (B2B when the customer has a valid Saudi VAT number, otherwise B2C), B2B (standard) or B2C (simplified).
- On the invoice, the E-Invoice Type field starts from the customer's and can be changed for that invoice. When it is B2B and the customer is missing something ZATCA needs, the field turns red and a warning lists what is missing. You can fix the customer with the edit button beside the customer box.
- A credit note is always the same type as its invoice (see Credit notes).
What happens when you post
Fiscal sends the document to ZATCA as soon as it is posted. The result shows on the line under the buttons in the invoice or credit note center:
| Shown | Meaning | What to do |
|---|---|---|
| Cleared by ZATCA / Reported to ZATCA | ZATCA accepted it. | Nothing. Corrections are made with a credit note. |
| Waiting for ZATCA's answer. | The gateway or ZATCA didn't answer, so the result isn't known. | Fiscal resends it automatically. You can click Resend. It is sent unchanged. |
| Not accepted by ZATCA: and the reason | Rejected (Failed). | Correct the document (or the customer) and click Resend. |
| Waiting for an earlier document | ZATCA takes each company's documents in order, so while one is not accepted the later ones wait. | Deal with the earlier document. This one follows automatically. |
| Not sent to ZATCA yet. | It was never sent. | Click Send. |
The E-Invoice Queue
Open Sales›E-Invoice Queue (shown only when Phase 2 is on). It lists every invoice and credit note ZATCA hasn't accepted yet, oldest Counter first, with the Status and the Last Message.
- Resend sends one document again. Resend All in Order sends them all in counter order.
- A Failed document can be corrected first. A Pending one is resent unchanged, and Fiscal retries those automatically.
- Totals differ marks a document ZATCA accepted with totals different from Fiscal's. Correct it with a credit note and a new document.
Printing and the QR code
- The QR code is printed where the print template has the
{{EInvoiceQrImageBase64}}placeholder, and is included in the emailed PDF (see Print templates). - Phase 1, and Phase 2 B2C documents: Fiscal makes the QR code, so the document can be printed and handed over at once.
- Phase 2 B2B documents carry ZATCA's QR code and can't be printed, emailed or shared until ZATCA has cleared them. You can still look at the preview. It is stamped PREVIEW ONLY — NOT A VALID TAX INVOICE with a large NOT CLEARED across the page.
Don't remove the QR code or the VAT details from your invoice print templates (see Print templates). Without them, the document isn't a valid tax invoice in Saudi Arabia.
Editing and cancelling
- A document can be edited while it hasn't been sent, or after ZATCA rejected it (Failed).
- Once ZATCA has accepted it, it can't be edited or cancelled. Issue a credit note.
- While the answer is unknown (Pending), it can't be edited. Resend it.
- An invoice that was handed to the gateway can't be cancelled, even if it was rejected. Correct it and resend it, or issue a credit note once it is accepted.
Documents dated before the Phase 2 start date
Invoices and credit notes dated before the Phase 2 Start Date were issued before your company joined Phase 2:
- they are never sent to ZATCA, and keep their Phase 1 QR code;
- they print, email, edit and cancel as before, without the Phase 2 checks;
- a credit note for one of them, dated on or after the start date, is sent to ZATCA normally.
While Phase 2 is on, a new invoice or credit note can't be dated before the start date, and a document dated on or after it can't be moved before it.
Company details on e-invoices
The screen shows the details that go on your e-invoices: Company Name (EN), Company Name (AR), VAT Registration No. and Country. They come from your company record and can't be changed here. If one of them is wrong or missing (the screen warns you when the VAT number is missing), contact Exler IT Hub support. E-invoicing doesn't work without a VAT registration number.
Also fill in your national address in the Company profile.