> ## Documentation Index
> Fetch the complete documentation index at: https://docs.filexpress.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Migration to electronic invoicing v2

> How to move your El Salvador company to version 2 of the electronic tax documents, test it, and go back to version 1 if you need to

The Ministry of Finance (Hacienda) published **version 2** of the electronic tax documents (DTE). FileXpress supports both versions at the same time: **you decide when to migrate** your company and you can go back to version 1 at any time. It applies only to **El Salvador** companies.

> [!WARNING]
>
> **Important dates.** Starting **November 3, 2026** your company can switch to version 2 from **System → Advanced settings**. Hacienda set **December 1, 2026 as the deadline to start** with version 2.

> [!WARNING]
>
> **Migrating is not just flipping a switch.** Before issuing with version 2 in production you must **request the tests at [factura.gob.sv](https://factura.gob.sv)**, **complete the version 2 tests** with a successful response from Hacienda, and only then **go to production**. This takes time: **start as soon as possible and don't leave it for the last days of November.**

## The full path: from testing to production

**1. Request the tests at factura.gob.sv**

Go to Hacienda's electronic invoicing portal and request the version 2 tests for your company. Without that step Hacienda will not receive test documents from you or authorize you to issue. You can also **contact FileXpress support at [soporte@filexpress.app](mailto:soporte@filexpress.app)** so we can guide you through the request and the tests.

**2. Prepare FileXpress**

Complete the district of your branches (and of your customers, suppliers, and donors) and review the requirements in **System → Advanced settings**.

**3. Turn on version 2 with the company in the test environment**

In the company's Special Settings leave the **test environment** on and, in **Advanced settings**, click **Migrate to version 2**. Everything you issue from there goes to Hacienda's test environment.

**4. Complete the minimum tests**

Issue documents of each type you use until you meet the **successful transmission tests** (with reception seal), including events. See the table below.

**5. Go to production**

When Hacienda confirms your tests, switch the company's environment to **production**. Version 2 stays active. If you use several companies, repeat the process in each one.

### Minimum tests required by Hacienda

Hacienda's functional manual 2.0 sets how many successful transmissions it needs per document type. Meet those for **the documents your company issues**; confirm in the portal what is required of you.

| Document | Minimum tests |
| - | - |
| Invoice (Factura) | 90 |
| Tax credit invoice (Comprobante de crédito fiscal) | 75 |
| Delivery note (Nota de remisión) | 50 |
| Credit note (Nota de crédito) | 50 |
| Debit note (Nota de débito) | 25 |
| Export invoice (Factura de exportación) | 90 |
| Excluded subject invoice (Factura de sujeto excluido) | 25 |
| Donation receipt (Comprobante de donación) | 25 |
| Each event (invalidation, contingency, return, special operations) | 5 |

> [!NOTE]
>
> Migrating does not modify the documents you already issued. It only changes how **new** documents are built.

## What changes with version 2

| Topic | Change |
| - | - |
| **District** | The issuer's and receiver's addresses add the **district** (Hacienda catalog), in addition to the department and municipality. |
| **Version of each document** | Invoice 2, Tax credit invoice 4, Delivery note 4, Credit note 4, Debit note 4, Export invoice 3, Excluded subject invoice 2, Donation receipt 2, Invalidation 3, Contingency 4. |
| **Credit and debit notes** | They detail VAT (IVA), perception, and withholding per line, and the receiver is identified with document type and number. They require the related document. |
| **Remarks** | All documents carry the remarks field. |
| **Export invoice** | Includes the regime type (for example, definitive export) alongside the regime. |
| **Excluded subject invoice and donation** | The way the parties are identified changes (in the donation, the issuer is whoever receives the donation and the receiver is the donor). |

Amounts, per-line VAT, special taxes, and rounding are calculated the same as in version 1.

## Invalidations in version 2

The invalidation event also moves to version 3 and follows the **document** you invalidate: a document issued in version 1 is invalidated with the version 1 event, and one issued in version 2, with the version 3 one.

Hacienda rules to keep in mind:

| Document | Event date | Deadline to transmit the invalidation |
| - | - | - |
| Tax credit invoice, credit and debit notes, delivery note, and donation receipt | The same generation date as the document | Until 23:59:59 on the tenth business day of the month following the period in which the document obtained its seal |
| Invoice, export invoice, and excluded subject invoice | Up to 3 months after the generation date | 3 months from the reception seal |

* If the reason is **error in the information** or **other**, first issue and transmit the replacement document: its generation code goes in the event. If the reason is **rescinding the operation**, there is no replacement document.
* An event transmitted late does not receive a seal and the document remains valid.
* The data of whoever **performs** and whoever **requests** the invalidation (name, document type, and number) is mandatory.

Invalidated documents are printed with the **INVALIDATED** mark and the invalidation detail: **event date**, **time Hacienda received it**, and **invalidation seal**, plus the reason.

## New events in version 2

With version 2, the return event and the special operations event are enabled in **DTE events**. See [DTE events](https://docs.filexpress.app/en/docs/ventas/eventos-dte.md).

## Before migrating

**1. Complete the district of your branches**

In **Branch settings → General → Data → Location**, choose each branch's district. It is mandatory: without it you will not be able to turn on version 2.

**2. Complete the district of your customers, suppliers, and donors**

It is not mandatory to turn it on, but it makes your documents come out accurate. If missing, the system uses the first district of the customer's department and records that.

**3. Keep the deadline in mind**

Hacienda set **December 1, 2026** to start with version 2; the date is shown on the migration screen. Testing and authorization take time, so plan with margin.

## Test first in the test environment

Before production, the company must work in the **test environment** with version 2 active (steps 3 and 4 of [The full path](#the-full-path-from-testing-to-production)). **Never** send test documents to the production environment, nor real documents to the test one.

## Turn on version 2

**1. Go to the home screen (/start)**

It is the screen where you choose company and branch.

**2. Open the company's Special Settings**

Click the gear icon next to the company and go to the **Advanced settings** tab.

**3. Review the requirements**

Under **Electronic invoicing v2 (El Salvador)** the pending requirements and warnings are shown, for example branches without a district.

**4. Migrate to version 2**

Click **Migrate to version 2**. If the company is already in production, the system asks you to confirm that you **have already completed the version 2 tests with Hacienda**: do not confirm without having finished them.

> [!WARNING]
>
> Only an **administrator** can turn the version on or revert it. Other users can only view the status.

## Go back to version 1

On the same screen, click **Go back to version 1** and confirm. From that moment new documents are again issued with version 1. Documents issued with version 2 are kept exactly as they were issued.

## Frequently asked questions

> [accordion] What happens to the invoices I already issued?
>
> They do not change. They keep the version they were issued with.

> [accordion] Can I migrate only some document types?
>
> No. Migration is per company and applies to all document types at once.

> [accordion] It won't let me migrate: it says districts are missing
>
> Go to the settings of each listed branch and choose its district.

> [accordion] My company is not from El Salvador
>
> Migration does not apply: Guatemala and the United States do not use this scheme.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.