中文電碼,又稱中文商用電碼、中文電報碼或中文電報明碼,原本是於電報之中傳送中文信息的方法。它是第一個把漢字化作電子訊號的編碼表。
自摩爾斯電碼在1835年發明後,一直只能用來傳送英語或以拉丁字母拼寫的文字。後來在1880年清朝政府僱用丹麥人設計了中文漢字電報。
中文電碼表採用了四位阿拉伯數字作代號,從0001到9999按四位數順序排列,用四位數字表示最多一萬個漢字、字母和符號。漢字先按部首,後按筆 劃排列。字母和符號放到電碼表的最尾。後來由於一萬個漢字不足以應付戶籍管理的要求,又有第二字面漢字的出現。在香港,兩個字面都採用同一編碼,由輸入員 人手選擇字面;在台灣,第二字面的漢字會在開首補上「1」字,變成5個數字的編碼。
The first telegraph code for Chinese was brought into use soon after the Great Northern Telegraph Company (大北電報公司 / 大北电报公司 Dàběi Diànbào Gōngsī) introduced telegraphy to China in 1871. Septime Auguste Viguier, a Frenchman and customs officer in Shanghai, published a codebook (Viguier 1872), succeeding Danish astronomer Hans Carl Frederik Christian Schjellerup’s earlier work.
In consideration of the former code’s insufficiency and disorder of characters, Zheng Guanying (鄭 觀應 / 郑 观应 Zhèng Guānyīng) compiled a new codebook in 1881. It remained in effect until the Ministry of Transportation and Communications printed a new book in 1929. In 1933, a supplement was added to the book.
After the establishment of the People’s Republic of China in 1949, the codebook forked into two different versions, due to revisions made in the Mainland China and Taiwan independently from each other. The Mainland version, the Standard Telegraph Codebook, adopted the simplified Chinese characters in 1981.