Gettext PO File Editor and MO Compiler
Translate PO catalogs entry by entry, check plural forms and format strings, merge a new POT template, and compile a binary MO file without installing gettext.
Runs in your browser. Your files never leave your device. See how to check
…
How to do it
- 1Open the catalog
Drop a PO, POT or MO file on the box.
- 2Check the header
Set Language and choose the Plural rule preset or type Plural-Forms.
- 3Translate
Pick an entry from the list and fill Translation or each plural Form box.
- 4Review guesses
Use the Fuzzy filter, compare with Previous source and untick Fuzzy.
- 5Update
Press Update from POT to merge a new template when the code changes.
- 6Save
Download the PO and press Compile MO for the binary file.
About this tool
Gettext is the oldest and still the most common way to translate software. WordPress themes and plugins, Django and Flask sites, PHP apps, GNOME and many Linux programs keep their text in PO files: plain text catalogs where each entry has the original string, its translation, flags and references to the source code. A POT file is the empty template that developers regenerate when strings change. The running program does not read PO files directly; it needs a compiled binary MO file. Normally that means installing the gettext command line tools or a desktop editor. This page does the whole job in your browser. It opens PO, POT and even MO files, shows each entry with its context, developer notes and source references, and gives one text box per plural form, labelled with example numbers so you know which form is which. It understands fuzzy entries, previous source strings, obsolete entries and multi-line strings, and writes them back in the standard layout.
Plural forms done right
Languages differ in how many plural forms they need: English has two, Japanese one, Russian three and Arabic six. The Plural-Forms header holds a small formula that picks the right form for a number. Choose a preset from the gettext manual or type your own formula; the editor evaluates it safely without running code and shows which numbers fall into each form, for example form 0 for 1, 21, 31 and form 1 for 2, 3, 4 in Russian. Type any number into Test a number to see which form it uses. Each plural entry then gets exactly as many boxes as the formula needs.
Fuzzy entries and catalog updates
When the developer adds or rewords strings, press Update from POT and pick the new template. The editor works like msgmerge: unchanged strings keep their translation, new strings are added empty, strings that changed slightly get the old translation as a fuzzy guess together with the previous source text, and strings that disappeared become obsolete. The fuzzy match threshold is adjustable. Untick Fuzzy once you have checked a guess.
Format strings
Entries flagged as c-format, python-format or php-format are checked for placeholders such as percent-s or named python placeholders. If the translation drops or adds one, the entry appears under Format issues, which helps avoid crashes at runtime.
Compiling MO
Compile MO writes a little-endian GNU MO file with the header and every translated entry, including message contexts and plural strings. Like msgfmt, it leaves out fuzzy, untranslated and obsolete entries, so a half-finished catalog still works with the source language as fallback. WordPress, Python gettext, PHP gettext and other readers load it directly.
Limits
The MO file has no hash table; readers fall back to binary search, which every common reader supports. Decompiling an MO file recovers strings and translations but not comments or references, because MO files do not store them. Long lines are not re-wrapped to 80 columns, which gettext tools accept without problems.
Worked example
A WordPress plugin ships a POT with 214 strings and an older German PO with 190 translations. After Update from POT, the report reads 176 kept, 9 fuzzy guesses, 29 new and 5 made obsolete. One fuzzy entry, Remove this item, carries the old translation Artikel entfernen with the previous source Remove item; the translator confirms it with a small change. The plural entry for percent-d item in your basket gets forms for n equal to 1 and for 0, 2 and 3. With 214 of 214 translated, Compile MO produces a 19 kilobyte file named de_DE.mo that the plugin loads at once.
Quick facts
- Category: Developer & Data
- Works in your browser, no sign-up, no upload.
- Your input stays on your device.
- Available in English.
- Content last reviewed:
- Official source: GNU gettext manual: PO files, plural forms and MO file format
Frequently asked questions
Can I open an MO file?
Yes. MO files are decompiled into an editable catalog. Comments and source references are not stored in MO files, so they cannot be recovered.
Why is my fuzzy translation missing in the app?
Fuzzy entries are left out of the MO file on purpose, exactly as msgfmt does, because they have not been checked. Untick Fuzzy after reviewing.
How do I set plural forms for my language?
Pick the preset that names your language, or type the formula from your project. The example numbers next to each box show which form is used.
Does Update from POT delete my old translations?
No. Strings no longer in the template are kept as obsolete entries at the end. Use Remove obsolete in the Obsolete filter when you are sure.
Can I create a POT from a PO?
Yes. POT template removes all translations, fuzzy flags and translator comments while keeping contexts, references and developer notes.
Is the catalog uploaded?
No. Parsing, merging and compiling happen in your browser, and a draft stays in this device's local storage.
