In 1638, Koxinga became a Xiucai (a successful candidate) in the imperial examination and became one of the twelve Linshansheng (廩膳生) of Nan'an. In 1641, Koxinga married the niece of Dong Yangxian, an official who was a Jinshi from Hui'an. In 1644, Koxinga studied at the Imperial Nanking University, where he met and became a student of the scholar Qian Qianyi.[7][8]

In 1644, Beijing fell to rebels led by Li Zicheng and the Chongzhen Emperor hanged himself on a tree at modern-day Jingshan Park in Beijing. Manchu armies aided by Wu Sangui's forces defeated the rebels and took the city. The Ming remnant forces retreated to Nanjing where the Prince Fu ascended to the throne as the Hongguang Emperor. The next year, the Manchu armies led by Dodo advanced south and conquered Yangzhou and Nanjing while the Ming leader defending Yangzhou, Shi Kefa, was killed. The Hongguang Emperor was captured and executed.

In 1645, Prince Tang was installed on the throne as the Longwu Emperor with support from Zheng Zhilong and his family.[9] The Longwu Emperor established his court in Fuzhou, which was controlled by the Zhengs. In the later part of the year, another Ming Prince Lu proclaimed himself as Regent (監國) in Shaoxing and established his own court there. Although Prince Lu and Longwu's regimes stemmed from the same dynasty, both of them pursued different goals.

It was due to the natural defences of Fujian and the military resources of the Zheng family, that the emperor was able to remain safe for some time.[10] The Longwu Emperor granted Zheng Zhilong's son, Zheng Sen, a new personal name, Chenggong (成功; Chénggōng; Sêng-kong; "success"), and the title of Koxinga ("Lord of the Imperial Surname").[10]

In 1646, Koxinga first led the Ming armies to resist the Manchu invaders and won the favour of the Longwu Emperor. The Longwu Emperor's reign in Fuzhou was brief, as Zheng Zhilong refused to support his plans for a counter-offensive against the rapidly expanding forces of the newly established Qing Dynasty by the Manchus. Zheng Zhilong ordered the defending general of Xianxia Pass (仙霞關), Shi Fu (a.k.a. Shi Tianfu, a relative of Shi Lang), to retreat to Fuzhou even when Qing armies approached Fujian. As such, the Qing army faced little resistance when it conquered the north of the pass. In September 1646, Qing armies broke through inadequately defended mountain passes and entered Fujian. Zheng Zhilong retreated to his coastal fortress and the Longwu Emperor faced the Qing armies alone. Longwu's forces were destroyed and he was captured and died shortly afterwards.[11]

The Qing forces sent envoys to meet Zheng Zhilong secretly and they offered to appoint him as the governor of both Fujian and Guangdong provinces if he would surrender to Qing. Zheng Zhilong agreed and ignored the objections of his family, surrendering himself to the Qing forces in Fuzhou on 21 November 1646.[12] Koxinga and his uncles were left as the successors to the leadership of Zheng Zhilong's military forces. Koxinga operated outside Xiamen and recruited many to join his cause in a few months. He used the superiority of his naval forces to launch amphibious raids on Manchu-occupied territory in Fujian and he managed to take Tong'an in Quanzhou prefecture in early 1647. However, Koxinga's forces lacked the ability to defend the newly occupied territory.[13]

Following the fall of Tong'an to Zheng, the Manchus launched a counterattack in the spring of 1647, during which they stormed the Zheng family's hometown of Anping. Koxinga's mother, Lady Tagawa, had come from Japan in 1645 to join her family in Fujian (Koxinga's younger brother, Tagawa Shichizaemon, remained in Japan).[14] She did not follow her husband to surrender to the Qing Dynasty. She was caught by Manchu forces in Anping and committed suicide after refusal to submit to the enemy, according to traditional accounts.[15]

By 1650, Koxinga was strong enough to establish himself as the head of the Zheng family.[15] He pledged allegiance to the only remaining claimant to the throne of the Ming Dynasty, the Yongli Emperor. The Yongli Emperor was fleeing from the Manchus in south-western China with a motley court and hastily assembled army at the time. Despite one fruitless attempt, Koxinga was unable to do anything to aid the last Ming emperor.[15] Instead, he decided to concentrate on securing his own position on the southeast coast.

Koxinga enjoyed a series of military successes in 1651 and 1652 that increased the Qing government's anxiety over the threat he posed.[16] The fight carried out massacre in Zhangzhou.[17] Zheng Zhilong wrote a letter to his son from Beijing, presumably at the request of the Shunzhi Emperor and the Qing government, urging his son to negotiate with the Manchurians. The long series of negotiations between Koxinga and the Qing Dynasty lasted until November 1654. The Qing government appointed Prince Jidu (son of Jirgalang) to lead an attack on Koxinga's territory after the failed negotiations.[18]

On 9 May 1656, Jidu's armies attacked Jinmen, an island near Xiamen that Koxinga had been using to train his troops. Partly as a result of a major storm, the Manchus were defeated and they lost most of their fleet in the battle.[19] Koxinga had sent one of his naval commanders to capture Zhoushan island prior to Jidu's attack,[20] and now that the Manchus were temporarily without an effective naval force in the Fujian area, Koxinga was free to send a huge army to Zhoushan, which he intended to use as a base to capture Nanjing.

In 1661, Koxinga led his troops on a landing at Lakjemuyse (zh) to attack the Dutch colonists in Dutch Formosa. The Taiwanese Aboriginal tribes who were previously allied with the Dutch against the Chinese during the Guo Huaiyi Rebellion in 1652 turned against the Dutch during the Siege of Fort Zeelandia and defected to Koxinga's Chinese forces.[22] The Aboriginals (Formosans) of Sincan defected to Koxinga after he offered them amnesty, the Sincan Aboriginals then proceeded to work for the Chinese and behead Dutch people in executions, the frontier aboriginals in the mountains and plains also surrendered and defected to the Chinese on May 17, 1661, celebrating their freedom from compulsory education under the Dutch rule by hunting down Dutch people and beheading them and trashing their Christian school textbooks.[23] On 1 February 1662, the Dutch Governor of Formosa, Frederik Coyett, surrendered Fort Zeelandia to Koxinga. According to Frederick Coyett's account written after the siege to absolve himself of the Dutch defeat, during the siege, Koxinga's life was saved by a certain Hans Jurgen Radis of Stockaert, a Dutch defector who strongly advised him against visiting the overrun ramparts, which he knew would be blown up by the retreating Dutch forces.[24] This claim of a Dutch defector only appears in Coyett's account and Chinese records make no such mention of any defector. In the peace treaty, Koxinga was styled "Lord Teibingh Tsiante Teysiancon Koxin" [2]. This effectively ended 38 years of Dutch rule on Taiwan. Koxinga then devoted himself to transforming Taiwan into a military base for loyalists who wanted to restore the Ming Dynasty.

In 1662, Koxinga's forces raided several towns in the Philippines. Koxinga's chief adviser was an Italian friar named Vittorio Riccio, whom he sent to Manila to demand tribute from the colonial government of the Spanish East Indies, threatening to attack the city if his demands were not met.[25]

The Spanish refused to pay the tribute and reinforced the garrisons around Manila, but the planned attack never took place due to Koxinga's sudden death in that year after expelling the Dutch on Taiwan.[26]

Koxinga's threat to invade the islands and expel the Spanish eventually caused the Spanish failure to conquer the MuslimMoro people in Mindanao. The threat of Chinese invasion forced the Spanish to withdraw their forces to Manila, leaving some troops in Jolo and by Lake Lanao to engage the Moro in protracted conflict, while Zamboanga in Mindanao was immediately evacuated upon Koxinga's threats. The Spanish were also forced to abandon their colony in the Maluku Islands (Moluccas) and withdraw their soldiers there to Manila.

Tonio Andrade judged that Koxinga would most likely have been able to defeat the Spanish[27]

Koxinga died of malaria at the age of 37. There were speculations that he died in a sudden fit of madness when his officers refused to carry out his orders to execute his son Zheng Jing. Zheng Jing had had an affair with his wet nurse and conceived a child with her.[28] Zheng Jing succeeded his father as the King of Tungning.

Zheng Chenggong’s short but eventful career was characterised by family tension and conflicting loyalties. The title of Koxinga ("Lord of the Imperial Surname") was one that Zheng himself used during his lifetime to emphasize his status as an adopted son of the deposed imperial house, and hence it was also a declaration of ongoing support to the Ming dynasty.[29] Despite his deliberate self-identification as the noble, loyal vassal of a vanquished master, Koxinga’s actual relationship with the Longwu Emperor lasted only twelve months or so, beginning in September 1645 and ending with the Emperor's death the following year.[30] Although many secondary sources claim that the two men shared a "close bond of affection", there is an absence of any reliable contemporary evidence on Koxinga’s relationship with the Longwu Emperor.[31]

In contrast, Koxinga’s father Zheng Zhilong left his Japanese wife not long after the birth of his son;[32] Koxinga would be a boy of seven when he finally joined his father on the Fujianese coast.[33]> It seems that Zheng Zhilong recognised his son’s talent and encouraged him in his studies and the pursuit of a career as a scholar-official, which would legitimise the power the Zheng family had acquired using sometimes questionable means.[7] Zheng Zhilong’s defection to the Qing must have seemed opportunistic and in stark contrast to Koxinga’s continued loyalty to the Ming. But it is difficult to deny that in refusing to submit to the Qing, Koxinga was risking the life of his father, and that the subsequent death of Zheng Zhilong could only be justified by claiming loyalty to the Ming.[34] It has even been suggested that Koxinga’s fury at the incestuous relationship between his son, Zheng Jing, and a younger son’s wet nurse was due to the fact that strict Confucian morality had played such a crucial role in justifying his lack of filial behaviour.[31]

The one possible exception to this may have been his relationship with his mother, which has generally been described as being extremely affectionate, particularly in Chinese and Japanese sources.[35] Their time together, however, was apparently very short – despite frequent entreaties from Zheng Zhilong for her to join him in China,[36] Koxinga’s mother would only be reunited with her son sometime in 1645, and a year later she would be killed when the Qing took Xiamen.[37]

A portrait of Zheng was in the hands of Yuchun who was his descendant in the eight generation.[38]

During the Siege of Fort Zeelandia, Koxinga executed Dutch missionary Antonius Hambroek and took his teenage daughter as a concubine.[39][40] Other Dutch women were sold to Chinese soldiers to become their wives.[41] In 1684 some of these Dutch wives were still captives of the Chinese.[42]

Koxinga's army also brought the Qinxi fraternal brotherhood into Taiwan, of which some of his army were members of the organization. In the present day, the Qinxi currently exists in Taiwan. The Hongmen are associated with them.[44]

Koxinga is regarded as a hero in the People's Republic of China, Taiwan, and Japan, but historical narratives regarding Koxinga frequently differ in explaining his motives and affiliation. Japan treats him as a native son and emphasized his maternal link to Japan in propaganda during the Japanese occupation of Taiwan.[46] The People's Republic of China considers Koxinga a national hero for driving the imperialist Dutch away from Taiwan and establishing ethnic Chinese rule over the island.[46] On mainland China, Koxinga is honoured as the “Conqueror of Taiwan, Great Rebel-Quelling General”[47] a military hero who brought Taiwan back within the Han Chinese sphere of influence through expanded economic, trade and cultural exchanges. In China, Koxinga is honoured without the religious overtones found in Taiwan.[48][clarification needed]

The Republic of China, which withdrew to Taiwan after losing the Chinese Civil War, regards Koxinga as a patriot who also retreated to Taiwan and used it as a base to launch counterattacks against the Qing Dynasty of mainland China. In Taiwan, Koxinga is honored as the island’s most respected saint for expelling the Dutch and seen as the original ancestor of a free Taiwan, and is known as Kaishan Shengwang, or “the Sage King who Opened up Taiwan”[48] and as “The Yanping Prince",[49] referring to the Kingdom of Tungning, which he established in modern-day Tainan.

In Taiwan, Koxinga is remembered and revered as a divine national hero with hundreds of temples, schools, tertiary educations, and other public centers named in his honor. Koxinga is accredited with replacing Dutch colonial rule with a more modern political system. Furthermore, Koxinga transformed Taiwan into an agrarian society through the introduction of new agricultural methods such as the proliferation of iron farming tools and new farming methods with cattle. For these reasons, Koxinga is often associated with “hints of [a] consciousness of Taiwanese independence.”[47]

However, not all Taiwanese accept the popularized interpretation of the Koxinga legacy. Supporters of Taiwanese independence are skeptical about embracing the Koxinga legacy. Koxinga’s mixed Japanese heritage (the Japanese were an occupying force for 50 years between 1895 and 1945) and the positive connotations in mainland China have all made acceptance by Taiwan independence supporters problematic.

In mainland China, Koxinga is considered a positive historical but human figure (not deified as he often is in Taiwan).[clarification needed] Koxinga’s retreat to Taiwan is seen largely as an inspirational story of Chinese nationalists seeking refuge against hostile forces. Koxinga’s aspirations to see Taiwan united with the mainland is often accentuated. Furthermore, Koxinga facilitated the settlement of a large number of Han Chinese to Taiwan who brought with them their Han cultures, traditions, and languages. As a direct result, Han Chinese make up approximately 98% of the Taiwanese population today.

There are hundreds of public pieces, shrines dedicated to and worship Koxinga. The Koxinga Temple in Tainan City, Taiwan, is perhaps the most interesting as it is “the only Fujianese style shrine in Taiwan.”[50] The temple “illustrat[es] the geographic connection between Taiwan and the Mainland, [whilst] describ[ing] the evolution of life from the past to the present,”[50] which means that the temple acknowledges that Koxinga is a legacy shared by both Taiwan and the Mainland and that this perhaps is still important today.

In Mainland China however, there is only one official memorial to their ‘conqueror of Taiwan’ and that is on Gulang Island of Xiamen, Fujian Province, which is positioned directly across Taiwan’s Kinmen. The imposing statue of Zheng Chenggong in full military regalia, gazes over the water facing Taiwan.

Whilst “the statue of Zheng portrays a clean-shaven young general in armour … [in] Taiwan, Koxinga seldom appears as a warrior. His portraits show him as a Ming noble in civilian robes – and wearing a small beard, a symbol of seniority and sobriety.” [48]

This difference in commemoration of the Koxinga story illustrates the wide difference in attitudes on either side of the Taiwan Strait on the issue of Taiwan sovereignty.

^Carioti, "The Zhengs' Maritime Power in the International Context of the 17th Century Far East Seas: The Rise of a 'Centralised Piratical Organisation' and Its Gradual Development into an Informal 'State'", p. 41, n. 29.

^Kennedy, Brian; Guo, Elizabeth (2008). Chinese Martial Arts Training Manuals: A Historical Survey (2, illustrated ed.). Berkeley, Calif.: Blue Snake. p. 152. ISBN978-1-58394-194-2. OCLC182663920. The Qinxi Tong is an example of a non-criminal fraternal organization. The original Qinxi group in Taiwan was made up of men who had been part of Koxinga's forces...affiliation with...the Hung Men...The Taiwanese Qinxi fraternal organization is still active, teaching martial arts and engaging in other activities.