Regarded as a diplomatic coup for Beijing, China and Panama signed a joint communique here formally establishing diplomatic relations.
Chinese Foreign Minister Wang Yi held a meeting with Isabel Saint Malo de Alvarado, Panama's vice president and foreign minister, state-run Xinhua news agency reported.
They signed the joint communique in which Panama has recognised One China, meaning that Taiwan is part of the Chinese mainland.
Taiwan expressed "anger and regret" over the "very unfriendly" diplomatic turn by Panama that "yielded to economic interests by the Beijing authorities".
More From This Section
Last June Taiwan's leader Tsai Ing-wen, a strong advocate of Taiwan's independence from China visited Panama, on her first overseas trip as President.
The switch by Panama leaves Taiwan with a handful of allies around the world.
Few months ago, Sao Tome and Principe has switched sides. Taiwan's foreign ministry condemned the move, alleging the island nation had demanded a huge amount of financial support.
The move by Panama comes as China began construction of a container port with natural gas facilities in northern province of Colon last week.
Taiwan, which broke away from China in 1949, is coming under immense pressure from China's push with huge funds of Belt and Road Initiative. Panama is the latest country to cut ties with Taiwan.
Taiwan has left with few allies, mostly small countries. They include Belize, El Salvador, Haiti, Nicaragua, St Kitts and Nevis, St Vincent & the Grenadines, the Dominican Republic, Guatemala, Paraguay, Honduras and Saint Lucia In Africa: Burkina Faso and Swaziland, The Holy See, Kiribati, Nauru, the Solomon Islands, Tuvalu, the Marshall Islands and Palau.
Chinese companies are developing ports in Panama, and Chinese state firms are said to have expressed interest in developing the land around the Panama Canal once the country opens a tender for it later this year.
The Panama Canal is a vital shipping route. As China expands its global trade ambitions with its One Belt One Road infrastructure-building initiative, access to the eastern coasts of both South America and the US is expected to be of growing importance for Beijing, the report said.