History of Lima
The history of Lima, the capital of Peru, began with its foundation by Francisco Pizarro on January 18, 1535. The city was established on the valley of the Rímac River in an area populated by the Ichma polity. It became the capital of the Viceroyalty of Peru and site of a Real Audiencia in 1543. In the 17th century, the city prospered as the center of an extensive trade network despite damage from earthquakes and the threat of pirates. However, prosperity came to an end in the 18th century due to an economic downturn and the Bourbon Reforms. The population of Lima played an ambivalent role in the 1821–1824 Peruvian War of Independence; the city suffered exactions from Royalist and Patriot armies alike. After independence, Lima became the capital of the Republic of Peru. It enjoyed a short period of prosperity in the mid-19th century until the 1879–1883 War of the Pacific when it was looted and occupied by Chilean troops. After the war, the city went through a period of demographic expansion and urban renewal. Population growth accelerated in the 1940s spurred by immigration from the Andean regions of Peru. This gave rise to the proliferation of shanty towns as public services failed to keep up with the city expansion. Foundation

In the pre-Columbian era, the location of what is now the city of Lima was inhabited by several Amerindian groups. Prior to the arrival of the Inca Empire, the valleys of the Rímac and Lurín rivers were grouped under the Ichma polity. Their presence left a mark in the form of some 40 pyramids associated to the irrigation system of the valleys. In 1532, a group of Spanish conquistadors led by Francisco Pizarro ambushed the Inca ruler Atahualpa and searched for a suitable place to establish his capital. His first choice was the city of Jauja, located amid the Andes, however this location was regarded as inconvenient for its high altitude and being far from the sea. Spanish scouts reported a better site in the valley of the Rímac, which was close to the Pacific Ocean, had ample water and wood provisions, extensive fields and fair weather. Pizarro thus founded the city of Lima in Peru's central coast on January 18, 1535. Carlos Huerta writes in his Chronology of the conquest of the kingdoms of Peru – Cronología de la conquista de los Reinos del Perú:

In August 1536, the new city was besieged by the troops of Manco Inca, the leader of an Inca rebellion against Spanish rule. The Spaniards and their native allies, headed by Pizarro himself, defeated the rebels after heavy fighting in the city streets and its surroundings. On November 3, 1536, the Spanish Crown confirmed the founding and, on December 7, 1537, Charles V, Holy Roman Emperor granted a coat of arms to the city. Colonial period

Over the next few years, Lima shared the turmoil caused by struggles between different factions of Spaniards. At the same time it gained prestige as it was designated capital of the Viceroyalty of Peru and site of a Real Audiencia in 1543. Latin America and Lima's first university, the National University of San Marcos was established in 1551 and its first printing press in 1584. Lima also became an important religious center, a Roman Catholic diocese was established in 1541 and converted to an archdiocese five years later. In 1609, the city held celebrations for the beatification of Ignatius of Loyola. Lima flourished during the 17th century as the center of an extensive trade network which integrated the Viceroyalty of Peru with the Americas, Europe and the Far East. Its merchants channeled Peruvian silver through the nearby port of Callao and exchanged it for imported goods at the trade fair of Portobelo in modern-day Panama. This practice was sanctioned by law as all trade from the Viceroyalty was required to go through Callao on its way to and from overseas markets. The resulting economic prosperity of the city was reflected in its rapid growth, population expanded from about 25,000 in 1619 to an estimated 80,000 in 1687. However, Lima was not free from dangers. On October 20 and December 2, 1687, powerful earthquakes destroyed most of the city and its surroundings. The outbreaks of disease and food shortages which followed the disaster caused a reduction of the population to under 40,000 by 1692. A second threat was the presence of pirates and privateers in the Pacific Ocean. A Dutch naval expedition led by Jacques l'Hermite attacked the port of Callao in 1624 but was repelled by Viceroy Diego Fernández de Córdoba. In the 1680s, English buccaneers proliferated in the waters of the Pacific until they were routed by Lima merchants in 1690. As a precautionary measure, Viceroy Melchor de Navarra y Rocafull built the Lima City Walls between 1684 and 1687. The 1687 earthquake marked a turning point in the history of Lima as it coincided with a recession in trade, a reduction of silver production and economic competition by other cities such as Buenos Aires. To add to these problems, on October 28, 1746, a powerful earthquake severely damaged the city and destroyed Callao, forcing a massive rebuilding effort under Viceroy José Antonio Manso de Velasco. This disaster led to an intense devotion for an image of Christ called The Lord of the Miracles, which has been taken out in procession every October since 1746. During the late colonial period, under the rule of the House of Bourbon, the ideas of the Enlightenment on public health and social control shaped the development of Lima. New buildings undertaken during this period include a cockfighting coliseum and a bullring, the Plaza de toros de Acho, as well as the General Cemetery. The first two were built to regulate these popular activities by centralizing them at a single venue, while the cemetery put an end to the practice of burials at churches which public authorities had come to realize were unhealthy. Independence

During the second half of the 18th century, Lima was adversely affected by the Bourbon Reforms as it lost its monopoly on overseas trade and the important mining region of Upper Peru was transferred to the Viceroyalty of the Río de la Plata. This economic decline made the city's elite dependent on royal and ecclesiastical appointment and thus, reluctant to advocate independence. In the 1810s, the city became a Royalist stronghold during the South American wars of independence led by a strong viceroy, José Fernando de Abascal y Sousa. A combined expedition of Argentinian and Chilean patriots under General José de San Martín managed to land south of Lima on September 7, 1820 but did not attack the city. Faced with a naval blockade and the action of guerrillas on land, Viceroy José de la Serna was forced to evacuate the city in July 1821 to save the Royalist army. Fearing a popular uprising and lacking any means to impose order, the city council invited San Martín to enter Lima and signed a Declaration of Independence at his request. However, the war was not over; in the next two years the city changed hands several times and suffered exactions from both sides. By the time the war was decided, at the Battle of Ayacucho on December 9, 1824, Lima was considerably impoverished. Republican period

After the war of independence, Lima became the capital of the Republic of Peru but economic stagnation and political turmoil brought its urban development to a halt. This hiatus ended in the 1850s, when increased public and private revenues from guano exports led to a rapid expansion of the city. In the next two decades, the State funded the construction of large size public buildings to replace colonial establishments; these included the Central Market, the General Slaughterhouse, the Mental Asylum, the Penitentiary, and the Dos de Mayo Hospital. There were also improvements in communications; a railroad line between Lima and Callao was completed in 1850 and an iron bridge across the Rímac River, the Balta Bridge, was opened in 1870. The city walls were torn down in 1872 as further urban growth was expected. However, the export-led economic expansion also widened the gap between rich and poor, fostering social unrest. During the 1879–1883 War of the Pacific, Chilean troops occupied Lima after defeating Peruvian resistance in the battles of San Juan and Miraflores. The city suffered the depredations of the invaders, who looted public museums, libraries and educational institutions. At the same time, angry mobs attacked wealthy citizens and the Asian population, sacking their properties and businesses. After the war, the city underwent a process of urban renewal and expansion from the 1890s up to the 1920s. As downtown Lima had become overcrowded, the La Victoria residential area was established in 1896 as a working-class neighborhood. During this period the urban layout was modified by the construction of big avenues which crisscrossed the city and connected it with neighboring towns such as Miraflores. In the 1920s and 1930s, several buildings of the historic centre were rebuilt including the Government Palace and the Municipal Palace. On May 24, 1940, an earthquake hit the city, which at that time was mostly built out of adobe and quincha. In the 1940s, Lima started a period of rapid growth spurred by immigration from the Andean regions of Peru. Population, estimated at 600,000 in 1940, reached 1.9 million by 1960 and 4.8 million by 1980. At the start of this period, the urban area was confined to a triangular area bounded by the city's historic center, Callao and Chorrillos; in the following decades settlements spread to the north, beyond the Rímac River, to the east, along the Central Highway, and to the south. Immigrants, at first confined to slums in downtown Lima, led this expansion through large-scale land invasions which gave rise to the proliferation of shanty towns, known as barriadas, renamed as pueblos jóvenes  in the 1980s and latter called "Human Settlements" during the 1990s. Major public works were carried out throughout this period, mainly under the governments of Manuel A. Odría (1948–1956) and Juan Velasco Alvarado (1968–1975). Brutalism dominated in the 1970s as exemplified in the massive headquarters built for Petroperú, the state-owned petroleum company. According to the 1993 census, the city population had reached 6.4 million,  28.4% of the total population of Peru compared to just 9.4% in 1940. See also
 Historic Centre of Lima
 History of Peru
 List of mayors of Lima
 Timeline of Lima

Notes

References

 Andrien, Kenneth. Crisis and decline: the Viceroyalty of Peru in the seventeenth century. Albuquerque: University of New Mexico Press, 1985. Anna, Timothy. The fall of the royal government in Peru. Lincoln: University of Nebraska Press, 1979. Clayton, Lawrence. "Local initiative and finance in defense of the Viceroyalty of Peru: the development of self-reliance". Hispanic American Historical Review 54 (2): 284–304 (May 1974). DOI 10.2307/2512570
 Conlee, Christina, Jalh Dulanto, Carol Mackay and Charles Stanish. "Late Prehispanic sociopolitical complexity". In Helaine Silverman (ed. ), Andean archaeology. Malden: Blackwell, 2004, pp. 209–236. Dietz, Henry. Poverty and problem-solving under military rule: the urban poor in Lima, Peru. Austin : University of Texas Press, 1980. Hemming, John. The conquest of the Incas. London: Macmillan, 1993. Higgings, James. Lima. A cultural history. Oxford: Oxford University Press, 2005. Murillo, Félix Alfaro. Lima Metropolitana perfil socio-demográfico. Lima: Instituto Nacional de Estadística e Informática, 1996. Retrieved on August 12, 2007. Huerta, Carlos: Cronología de la Conquista de los Reinos del Perú (1524–1572). Lima, 2013. Klarén, Peter. Peru: society and nationhood in the Andes. New York: Oxford University Press, 2000. Ramón, Gabriel. "The script of urban surgery: Lima, 1850–1940". In Arturo Almandoz (ed. ), Planning Latin America's capital cities, 1850–1950. New York: Routledge, 2002, pp. 170–192. Walker, Charles. "The upper classes and their upper stories: architecture and the aftermath of the Lima earthquake of 1746". Hispanic American Historical Review 83 (1): 53–82 (February 2003).