Fernão Pires de Andrade (also spelled as Fernão Peres de Andrade; in contemporary sources, Fernam (Fernã) Perez Dandrade) (d. 1552) was a Portuguese merchant, pharmacist, and diplomat who worked under the explorer and colonial administrator Afonso de Albuquerque. His encounter with Ming China in 1517—after initial contacts by Jorge Álvares and Rafael Perestrello in 1513 and 1516, respectively—marked the resumption of direct European commercial and diplomatic contact with China. (Even though there were Europeans in Medieval China, notably Marco Polo, that period of contact had been interrupted by the fall of the Yuan dynasty.) 
 Although de Andrade's mission was initially a success that allowed a Portuguese embassy to proceed all the way to Beijing, relations were soon spoiled by culminating events that led to an extremely negative impression of the Portuguese in China. This included acts of his brother Simão that enraged the Chinese, false reports of the Portuguese being cannibals of kidnapped Chinese children and true reports of their conquest of Malacca, a loyal Ming tributary state. Normalized trade and relations between Portugal and the Ming dynasty would not resume until the late 1540s and the 1557 establishment of Portuguese rule over Macau.
 Andrade was referred to as a "Folangji" (佛郎機) in Ming dynastic archives. Folangji comes from Franques or Franks, which was a generic name the Muslims called Europeans since the Crusades, and which spawned the Indian-Southeast Asian term ferengi. The Chinese adopted the convention when they first thought the Portuguese were related to those Muslim guides and interpreters during Fernão's first encounter and before Europeans directly convened with Chinese.
 Fernão Pires de Andrade commanded a vessel in the naval venture of the Portuguese explorer and conqueror Afonso de Albuquerque from Cochin in India to conquer the Malacca Sultanate in 1511. The Portuguese historian João de Barros (1496–1570) wrote that when a violent storm arose as Albuquerque's fleet entered the vast waters between Sri Lanka and Aceh, a ship commanded by Simão Martinho was sunk, but his entire crew was rescued by Fernão and taken aboard his ship. To make up for this loss, the Portuguese captured and commandeered five ships from Gujarat that were sailing between Malacca and Sumatra. The small fleet of Albuquerque engaged an enemy "junk" ship of the Javanese "Moors" near Polvoreira (likely Pulau Berhala, 160 miles from Malacca, between Belawan, Medan and Lumut, Perak). According to Barros, they fought against this ship for two days. The enemy crew employed tactics of lighting fire to its own ship as a means to burn Albuquerque's ships as they employed ramming techniques and close-range volleys of artillery. Although the ship surrendered; the Portuguese gained such an admiration for the junk and its crew that they nicknamed it O Bravo (The Brave Junk). The Portuguese crew pleaded with Fernão Pires to convince Albuquerque that the crew should be spared and viewed vassals of Portugal who were simply unaware of who they were actually fighting. Albuquerque eventually agreed to this.
 While writing of Afonso de Albuquerque's ventures in Sumatra, João de Barros noted that the Chinese were the first to control trade between Sumatra and India, and noted the presence of Chinese people living in Sumatra. Barros also noted that while Fernão Pires was loading Southeast Asian spices onto his ship in Pacem (a kingdom in Sumatra) in order to sell or present them as gifts in China, two different kings were killed and their position usurped. Apparently the usurpation of kings caused little tumult or crisis in this state, as Barros noted any leader there was believed by the locals not to have divine right to rule if he was able to be killed by a royal kinsman. Historian Mark Dion notes that Fernão related the same story in his writing, only adding that a Muslim in their society was the only acceptable replacement as ruler.
 After the conquest of Malacca in 1511, not only did the Portuguese monopolize the European spice trade, but they also met and traded avidly with Chinese merchants. When Portuguese under Diogo Lopes de Sequeira had earlier arrived in Malacca in 1509 to open trade relations, he was supported by the local Chinese merchants there (along with Javanese and Tamil merchants). D'Albuquerque sent Jorge Álvares to explore northward; his expedition sailed along the coast of Guangdong in 1513 and hoisted a flag on "Tuen Mun island". This mission was followed up later that year by Rafael Perestrello, who later traded with Chinese merchants of Canton in 1516. He provided an enticing report to other Portuguese on the lucrative trade in China. This prompted Andrade to speed up the course of his mission while stalled in Malacca and debate with his crew on whether to go to China or Bengal.
 King Manuel I authorized a trade mission in 1517 when Andrade set sail with seven cannon-armed merchant vessels with a Muslim interpreter on June 17, 1517. Andrade had been chosen for this mission in Lisbon back in 1515, so that—as a pharmacist—he could investigate the types of pharmaceutical drugs used in East Asia for the benefit of the Portuguese and Europe. Florentine merchant Giovanni da Empoli, who had written a report about trade with China while stationed in India, was also chosen for the mission as the chief commercial agent between the Portuguese and Chinese. However, Giovanni would die in China during the early mission on October 15, 1517 when the ship he was on accidentally caught on fire. Tomé Pires, a royal apothecary who had also traveled to India and written a landmark work in 1515 on Asian trade, was chosen as the chief ambassador for the mission.
 Although the mission was stalled once they lost a ship in the Strait of Malacca, they nonetheless landed at the Pearl River estuary on August 15 with eight ships and negotiated with Chinese officials for possible silk and porcelain trade at Canton. The Chinese naval commander of Nantou (under the jurisdiction of Zhongshan, located at the mouth of the Pearl River) stalled Andrade's small fleet of ships for an entire month while Andrade waited for permission to sail upriver to Canton. After Andrade threatened to sail upriver without permission, the naval commander finally decided to let him pass, granting him pilots to assist his travel.
 Once the ships sailed into port at Canton, they alarmed the Chinese residents and officials there by discharging cannon fire, what they believed was a friendly salute since the Chinese merchants had done so when the Portuguese earlier arrived in Malacca. Chinese officials became even more cautious in dealing with the Portuguese, since the deposed King of Malacca had been a loyal tributary to the imperial Ming court. The Portuguese explained that in deposing the Malaccan king, they were helping the Chinese merchants there who were being oppressed under his rule. In the eyes of the Canton officials, this added further negative speculations about the Portuguese visitors, because private Chinese overseas trade was banned under the current hai jin laws that stated only the Chinese government could conduct foreign trade.
 Although the local Canton officials watched the Portuguese and their ships closely, once the provincial authorities arrived at Canton they greeted the Portuguese with a warm reception, providing them comfortable lodgings and had their trade goods brought ashore. The Chinese became suspicious once again of Andrade, this time for being a spy, when he sent a ship along the Fujian coast to look for further trade prospects, but he left a good impression when he gave the order that any locals who might be harmed by a Portuguese should seek him for redress. Besides exploring Fujian, Andrade sent one of his captains named Jorge de Mascarenhas to explore the Ryukyu Islands after he heard of their beauty while stationed in Malacca.
 Simão de Andrade, brother to Fernão Pires, sailed from Malacca to China with a small crew on three junks in August 1519. Simão immediately made a bad impression upon the Chinese when he built a fort at the center of Tuen Mun, an island designated for all foreigners to trade. Soon after, Simão ceremoniously executed a Portuguese and barred other foreigners (mostly Siamese and other South East Asians) from trading on the island, which drew even more attention to him. When a Chinese official visited the island and began reasserting Ming authority over it, Simão became aggressive and hit him, knocking the official's hat off.
 The greatest offense to the Chinese was the supposed kidnapping of children by the Portuguese so they could eat them. In reality, Simão had earned the Portuguese a bad reputation for buying young Chinese slaves, presumably some of whom were kidnapped after Simão offered local Chinese huge sums of money for child slaves. In fact, some boys and girls from wealthy Chinese families were later found by Portuguese authorities at Diu in western India. However, there were no official reports of Simão's abuses, even though he stayed until September 1520; yet rumors of his behavior (which became associated with all Portuguese) no doubt reached as far as the court of Beijing, which would soon condemn the Portuguese for this and other reasons.
 Although he had left Canton, Simão de Andrade landed at Xiamen and Ningbo, establishing settlements there. Simão continued to defy local Chinese laws at Ningbo, and when his men were cheated on a trade deal with a Chinese man in 1545, Simão sent a band of armed men into the town, pillaged it, and took local women and young girls as their captives. The outraged locals banded together and slaughtered the Portuguese under Simão. A similar episode occurred later when Coelho de Sousa seized the house of a wealthy foreign resident in Jinzhou of Fujian, which led authorities to cut off supplies to the Portuguese; the Portuguese then attacked and ransacked a nearby village for supplies, which prompted Chinese authorities to destroy thirteen of their ships while thirty Portuguese survivors of this settlement fled to the Portuguese settlement at Macau in 1549.
 The embassy party left behind in Canton in 1518 proceeded north in January 1520 with the rest of the Portuguese under Tomé Pires and Fernão Pires de Andrade. The embassy reached Nanjing, where the Zhengde Emperor was touring in May 1520, granting the Portuguese embassy a quick audience. However, further diplomatic negotiations were to be resumed once the emperor returned to Beijing; hence, the Portuguese embassy was sent there to wait for the emperor's return.
 Although no Chinese sources detail the event, Portuguese sources tell of how the Portuguese were summoned on the first and fifteenth days of each lunar month to ceremoniously prostrate themselves before a wall of the Forbidden City to seek another audience with the emperor. From Beijing, the Portuguese embassy heard reports that the emperor reached Tongzhou in January 1521 and had the rebel Prince of Ning executed there. The Portuguese embassy had also become aware that ambassadors from the exiled King of Malacca were sent to Beijing seeking assistance from the Chinese emperor in expelling the conquering Portuguese so that their king could be reinstalled there. The Portuguese also knew of two officials in the Censorate—Qiu Daolong and He Ao— who sent memorials to the throne that condemned the Portuguese conquest of Malacca and that their embassy should be rejected. There were also reports sent to Beijing by Canton officials stating that the Portuguese were bothersome foreigners who sought to build their own trading post.
 With the death of the Zhengde Emperor on April 19, 1521, mourning ceremonies were initiated that cancelled all other ceremonies, including the reception of foreign embassies. The newly appointed Grand Secretary, Yang Tinghe, soon turned against the powerful eunuch influence at court, which had grown even more powerful under the Zhengde Emperor. Although Ming officials were of the opinion that only foreign tributary states listed during the beginning of the dynasty should be accepted at court, it was the eunuchs who wanted to expand commercial ties with new foreign countries. These desires were given free rein under the Zhengde Emperor, who was intrigued with and desired to learn about foreign and exotic peoples. However, with his death, eunuch influence at court was challenged by Yang Tinghe, who announced the rejection of the Portuguese embassy under Pires and Andrade the day after the emperor's death; the embassy was forced to leave and arrived back in Canton in September.
 Earlier, in April and May 1521, five Portuguese ships docked at Tuen Mun to begin trading, but were ordered to leave once officials came to the region to announce the emperor's death. The Portuguese refused this demand, so the Chinese sent a naval squadron to drive them out, sinking one ship, killing many, and taking the rest as prisoners (First Battle of Tamao). Two more Portuguese vessels arrived in June, were attacked by Chinese ships, but were able to fend off the Chinese attack. Three more Portuguese ships barely fended off another attack in September, the same month that Fernão Pires de Andrade and Tomé Pires arrived back at Canton. Ming authorities would not permit Fernão and Pires to see the prisoners captured in the sea battles and made inventories of their goods and the goods captured from the Portuguese ships.
 In August 1522, Martim Afonso de Melo Coutinho arrived at Tuen Mun with three ships, unaware of the conflict and expecting to meet with Chinese officials on establishing consent for a Portuguese trade base in China. Two of his ships were captured in a surprise Chinese attack, while the survivors escaped back to Portugal on the third ship (see Second Battle of Tamao). These encounters and others with the Portuguese brought the first breech-loading culverins into China, mentioned even by the philosopher and scholar-official Wang Yangming in 1519 when he suppressed Zhu Chenhao's rebellion in Jiangxi.
 The prisoners of these sea battles were eventually executed in 1523 for crimes of "robbery in the high seas" and cannibalism, while Tomé Pires was kept prisoner so that he could write letters to the King of Portugal, the Viceroy of Portuguese India, and the Governor of Malacca conveying the new Ming emperor's message that the Portuguese should leave Malacca and restore it to the rightful rule of its deposed king. By some accounts, Fernão Pires de Andrade simply died while imprisoned; others say Andrade was one of those beheaded when a crime of false credentials was placed upon him after a court examined if his embassy was legitimate or spurious due to negative accounts of the Portuguese (i.e. acts committed by those such as Fernão Pires' brother Simào). Tomé Pires died while living as a prisoner in China; there is speculation on whether Tomé Pires died in 1524 or 1540. Two survivors of this embassy were still alive around 1536, when they sent letters to Malacca and Goa detailing plans for how the Portuguese could capture Canton by force. Other survivors of these missions retired to nearby Lampaco (Lampa) in Guangdong, where a trade post would exist for several decades; in 1537, there were written records of the Portuguese having three warehouses at Lampa, Shangchuan Island, and Macau, and were initially allowed there with the excuse of drying their goods in a storm.
 Despite initial hostilities, good relations between the Portuguese and Chinese would resume in 1549 with annual Portuguese trade missions to Shangchuan Island, following an event where the Portuguese helped Ming authorities eliminate coastal pirates. In 1554, Leonel de Sousa—a later Governor of Macau— established positive relations through an agreement with Cantonese authorities and in 1557 the Ming court finally gave consent for a permanent and official Portuguese trade base at Macau. Although Fernão Pires de Andrade and his Portuguese comrades were the first to open up China to the West, another significant diplomatic mission reaching all the way to Beijing would not be carried out until an Italian, the Jesuit Matteo Ricci (1552–1610) ventured there in 1598.[citation needed]