Panama (undefined ), officially the Republic of Panama (República de Panamá), is a country in Central America, bordered by Costa Rica to the west, Colombia to the southeast, the Caribbean Sea to the north, and the Pacific Ocean to the south. The capital and largest city is Panama City, whose metropolitan area is home to nearly half the country's million people.
Panama was inhabited by indigenous tribes before Spanish colonists arrived in the 16th century. It broke away from Spain in 1821 and joined the Republic of Gran Colombia, a union of Nueva Granada, Ecuador, and Venezuela. After Gran Colombia dissolved in 1831, Panama and Nueva Granada eventually became the Republic of Colombia. With the backing of the United States, Panama seceded from Colombia in 1903, allowing the construction of the Panama Canal to be completed by the US Army Corps of Engineers between 1904 and 1914. The 1977 Torrijos–Carter Treaties led to the transfer of the Canal from the United States to Panama on December 31, 1999.
Revenue from canal tolls continues to represent a significant portion of Panama's GDP, although commerce, banking, and tourism are major and growing sectors. It is regarded as a high-income country. In 2015 Panama ranked 60th in the world in terms of the Human Development Index. In 2018, Panama was ranked seventh-most competitive economy in Latin America, according to the World Economic Forum's Global Competitiveness Index. Covering around 40 percent of its land area, Panama's jungles are home to an abundance of tropical plants and animals – some of them found nowhere else on the planet. Panama is a founding member of the United Nations and other international organizations such as OAS, LAIA, G77, WHO and NAM.
The definite origin of the name Panama is ultimately unknown. There are several theories. One postulates that the country was named after a commonly found species of tree (Sterculia apetala, the Panama tree). Another that the first settlers arrived in Panama in August, when butterflies abound, and that the name means "many butterflies" in one or several of indigenous Amerindian languages that were spoken in the territory prior to Spanish colonization. Most scientifically corroborated theory, that by Panamanian linguists, states that the word is a hispanicization of Kuna language word "bannaba" which means "distant" or "far away".
A commonly relayed legend in Panama is that there was a fishing village that bore the name "Panamá", which purportedly meant "an abundance of fish", when the Spanish colonizers first landed in the area. The exact location of the village is unspecified. The legend is usually corroborated by Captain Antonio Tello de Guzmán's diary entries, who reports landing at an unnamed village while exploring the Pacific coast of Panama in 1515; he only describes the village as a "same small indigenous fishing town". In 1517, Don Gaspar de Espinosa, a Spanish lieutenant, decided to settle a post in the same location Guzmán described. In 1519, Pedrarias Dávila decided to establish the Spanish Empire's Pacific port at the site. The new settlement replaced Santa María La Antigua del Darién, which had lost its function within the Crown's global plan after the Spanish exploitation of the riches in the Pacific began.
The official definition and origin of the name as promoted by Panama's Ministry of Education is the "abundance of fish, trees and butterflies". This is the usual description given in social studies textbooks.