Skip to main content
Uploading a TMX File

Upload a TMX file to Transifex.

Jacob Doulkeridis avatar
Written by Jacob Doulkeridis
Updated over 4 months ago

📝Note: Uploading TMX files is a feature only available on the Growth plan and up.


TMX (Translation Memory Exchange) is an industry-standard file format for Translation Memory. It lets you move TM data between systems and tools without losing your translations. With TMX files, you can, for example, import the TM from a tool you used previously or from any offline translation tool you work with.

Each project in Transifex has its own Translation Memory. To upload a TMX file:

  1. From the project navigation in the Dashboard, click on the project you want to import the TMX file to

  2. Click Settings

  3. Click on General in the submenu.

  4. Go to the Translation Memory Actions section and click the Import content from a TM… link.

    tm_import.png#asset:3472

  5. Select a file from your computer, then click Import.

    upload_tmx_new.png#asset:4552

    If you want to overwrite your existing TM with the contents of your TMX, check the box next to Overwrite existing TM and rebuild it from the TMX file. Since this is destructive behavior, we recommend you read the next section before proceeding.

    You can choose a specific language when selecting to overwrite TM:

    Overwriting-language.png#asset:4937

📝 Note

  • The maximum .tmx file size you can export from Transifex is 500MB.

  • The maximum .tmx file size you can import into Transifex is 100MB.


Supported Syntax in TMX File

Sample #1

Below, you can find a simplified version supported by Transifex with en as the source language and el as the target language:

...
<tu>
<prop type="context"></prop>
<tuv xml:lang="en">
<seg>Password</seg>
</tuv>
<tuv xml:lang="el">
<seg>Kωδικός</seg>
</tuv>
</tu>
...

Sample #2

Let's now consider the following part of a valid TMX file, with en as the source language and el as the target language:

...
<tu>
<prop type="context"></prop>
<tuv xml:lang="en" creationdate="20210511T084001" lastusagedate="20211108T090745">
<seg>Password</seg>
</tuv>
<tuv xml:lang="el" creationdate="20210930T145229" lastusagedate="20211108T090745">
<seg>Kωδικός</seg>
</tuv>
<tuv xml:lang="el">
<seg>Κωδικός χρήστη</seg>
</tuv>
<tuv xml:lang="el" creationdate="20210930T145229" lastusagedate="20210930T145457">
<seg>Προσωπικός κωδικός</seg>
</tuv>
</tu>
...

Transifex takes into account the lastusagedate attribute of <tuv> elements grouped under the same <tu> element for a specific target language as long as such attributes are included in the TMX file.

In this case, “Κωδικός“ would be deemed as the most recent translation entry (based on lastusagedate value) and “Κωδικός χρήστη“ as the most out-of-date one (no available lastusagedate value). Transifex prioritizes entries where the lastusagedate attribute is present (i.e., consider them up-to-date/more recent) so that they may be used during TM auto fill-up tasks.

Suppose all translation entries grouped under the same <tu> element for a specific target language do not use the lastusagedate attribute. In that case, the last translation version entry will be considered the most recent. The same rules apply when the <tu> element contains pluralized sources and translations.


What happens when you upload a TMX file

By default, when you upload a TMX file, Transifex adds entries from the file to your existing TM. In other words, the two TMs are merged, and existing entries in your TM are unaffected.

As an example, let's say you have a TM with the following entries, where the left column represents your source strings and the right column represents the translations:

  • A → A1

  • B → B1

  • C → C1

And you upload this TMX file:

  • A → A2

  • D → D1

Afterward, your TM will look like this:

  • A → A1

  • A → A2

  • B → B1

  • C → C1

  • D → D1

Both A1 and A2 are now present in your TM. Since A2 is newer, it will be used for Translation Memory Autofill, though both suggestions will be available to translators. If you want to delete A1, you can do so.

However, suppose you select the "Overwrite existing TM and rebuild it from the TMX file" option when uploading the TMX file. In that case, everything in your project's TM instance will be removed and replaced by the new entries after you hit Import.

Your TM will have the same content as the TMX file:

  • A → A2

  • D → D1

In both cases, existing translations will not be affected.


Filling TM without uploading a .tmx file

Suppose you have done translations in the past and have both the source and translation files but don’t have a TMX file available. In that case, it might still be possible to load the translation data from previous translations into your project’s translation memory.

A few things to keep in mind before proceeding:

  • Source and target files should be in the same file format;

  • Source and target strings should map, i.e., in case of a key-value structure, the same keys should be used for both source and translation entries; in case of a non-key-value file format, the same structure (new lines should be preserved in all files) should be followed by both source and translations files. This ensures the Transifex parser can map the translations to the corresponding source entries.

  • Translations in a specific target language should be in a separate file. For example, if you have translated your content into three different languages, you must have three different translation files, one per language.

If these requirements are met, you can proceed with creating a TM from your source and available translation files:

  1. Upload the translations to the same resource file in Transifex.

As a result, every translation string maps with the source string and automatically becomes a part of your project's TM.


💡Tip

Looking for more help? Get support from our Transifex Community Forum!

Find answers or post to get help from Transifex Support and our Community.

Did this answer your question?