About this tool
For years, Cambodian offices typed their documents in legacy Khmer fonts — Limon for NGO reports and school handouts, ABC and Khek for ministry circulars and print-shop layouts. A file saved in one of those fonts does not contain Khmer characters at all: it stores Latin byte codes that only draw Khmer letters while the matching font is installed. Copy a paragraph out of one today and you get strings like `sYsþI` instead of សួស្តី — unsearchable, untranslatable, unreadable on any device that lacks the font. This page converts that legacy text into Unicode Khmer, the encoding every modern phone, browser and website reads — Limon to Unicode, ABC-Zwsp to Unicode and Khek to Unicode, all from the same pane. Pick the encoding yourself or leave the selector on Auto-detect: the Limon to Unicode path, the ABC-Zwsp path and the Khek path each apply their own byte table, and the detector picks the one whose decode looks like real Khmer. Everything runs in your browser — paste the legacy text, press Convert, copy or download the result. What it does not do: it does not translate meaning, it does not render legacy fonts on screen, and it does not go from Unicode back to a legacy encoding — the paired Unicode to legacy converter handles that direction. Characters with no entry in the chosen table pass through unchanged and are counted for you, never guessed at.
How it works
Pressing Convert runs a pure function in your browser — convertLegacyToUnicode in lib/khmer-legacy-converter/converter.ts — with the encoding you selected. Under Auto-detect, the page first decodes your text under each of the three tables and scores how plausible each result is as real Khmer: a wrong table produces consonant clusters that cannot exist, like a subscript sign glued to a letter that has no subscript form, or vowel signs floating with no base consonant, so the highest-scoring table is usually the right one. The conversion pass then walks your text matching the longest known byte sequence first — legacy fonts pack some Khmer glyphs into two- and three-byte combinations that a naïve one-byte map scrambles — before falling back to the single-byte table. Those bytes decode in visual order, whereas Unicode demands logical order, so a reorder pass (reorder.ts: unicodeReorder) arranges every cluster the way Unicode specifies — subscripts, vowel signs and shifters land where a search box expects them. Characters the table does not define pass through unchanged and appear in the unmapped-characters chip under the output. Inputs over 10 KB convert inside a Web Worker so the page stays responsive; smaller text runs on the main thread. Your text never leaves the browser — the only telemetry is an anonymous usage event carrying counters such as length and unmapped count, never the text itself.
Use cases
- Opening an old .doc or .pdf and seeing garbled characters like sYsþI bgb¥Ún — paste the legacy text and get clean សួស្តី បងប្អូន back.
- A librarian digitising pre-2010 Cambodian publications whose source files are Limon-encoded and whose target repository requires Unicode text.
- A government officer migrating a Khek-encoded form template into a modern Unicode-based document system.
- A developer importing a legacy CSV of Cambodian records whose Khmer name column is Limon bytes, needing Unicode for a modern search index.
- A website team moving a Limon-era blog over to a current CMS that requires Unicode for proper indexing and rendering.
- A translator receiving a Khmer source file in ABC-Zwsp and needing clean Unicode to paste into a CAT tool.
- A researcher processing a corpus of 1990s–2000s Khmer newspapers whose text follows the original Limon encoding.
Verified conversion examples
| Encoding | Legacy text | Unicode Khmer |
|---|---|---|
| limon | sYsþI bgb¥Ún | សួស្តី បងប្អូន |
| limon | sMNYr nigcemøIy GMBI PasaExµr | សំណួរ និងចម្លើយ អំពី ភាសាខ្មែរ |
| abc-zwsp | sYsþI.bgbðÚn | សួស្តី បងប្អូន |
| abc-zwsp | qñaM.2026.Ex.11 | ឆ្នាំ ២០២៦ ខែ ១១ |
| khek | sYs¶I bgbíèn | សួស្តី បងប្អូន |
| khek | ekµg@kMBugeronGk§rExµr enAsalaeron | ក្មេងៗកំពុងរៀនអក្សរខ្មែរ នៅសាលារៀន |
Frequently asked questions
What is the Limon encoding?
Limon (the S1/S2 font family) is the most common legacy Khmer encoding: ministry letters, NGO reports, school handouts and theses typed before Unicode became standard were overwhelmingly saved in it. A Limon file stores Latin byte codes, not Khmer characters — the glyphs only appear while the Limon font is installed, which is why copied text looks like Latin gibberish today.
How do I know my document is Limon and not another font?
Open the original file and look at the font name in the toolbar — if it says Limon (or an S-family variant), this page is the right one. Without the file, paste a sentence here: the Limon table converts real Limon text into fluent Khmer immediately, while another encoding produces obvious garbage. Auto-detect also separates Limon from ABC-Zwsp and Khek on any reasonably long passage.
Why did the numbers in my Limon text become Khmer digits?
Limon assigns Khmer digit glyphs to the ASCII digit keys — in a Limon document, the bytes 0–9 draw as ០–៩. The converter restores that meaning, so 2026 in Limon text comes out as ២០២៦. If your document deliberately mixed a Latin font for numbers, that mixing is invisible in plain text and needs a manual pass on the affected lines.
Can I convert Limon to Unicode on my phone?
Yes — the conversion runs entirely in the browser, so it works on any phone or computer with no font installation, account or upload. Paste the Limon text into the box, press Convert and copy the Unicode result. The Limon font itself is never needed: the tool works from its byte table, not from the font file.
Data and accuracy
The page applies the three static mapping tables shipped in lib/khmer-legacy-converter/mappings/, resolved from fontdata.xml in the KhmerConverter project — the open-source converter the Khmer Software Initiative (KhmerOS) has maintained since 2006 for Limon, ABC, Khek and other legacy Khmer fonts. Because conversion is pure local computation there is no upstream feed to go stale — a wrong result means the pasted text is not the selected encoding, not stale data. The tables are regression-tested by the round-trip corpus that ships with the library.
Sources
- KhmerConverter — Khmer Software Initiative legacy-font converter (fontdata.xml tables) — Khmer Software Initiative / KhmerOS (GitHub)
- Khmer — Unicode code chart U+1780–U+17FF — Unicode Consortium
- Khmer alphabet — script and Unicode encoding — Wikipedia
- This tool’s own page — InKhmer
Content last reviewed 8 November 2026