The Los Angeles coastal area was first settled by the Tongva (or Gabrieleños) and Chumash Native American tribes thousands of years ago. The first Europeans arrived in 1542 in an expedition organized by the viceroy of New Spain and commanded by Juan Rodríguez Cabrillo, a Portuguese-born explorer who claimed the area of southern California for the Spanish Empire. However, he continued with his voyage up the coast and did not establish a settlement. The next contact would not come until 227 years later, when Gaspar de Portolà, along with Franciscan missionary Juan Crespí, reached the present site of Los Angeles on August 2, 1769. Crespí noted that the site had the potential to be developed into a large settlement.
In 1771, Franciscan friar Junípero Serra built the Mission San Gabriel Arcangel near Whittier Narrows, in what is now called San Gabriel Valley. In 1777, the new governor of California, Felipe de Neve, recommended to Antonio María de Bucareli y Ursúa, viceroy of New Spain, that the site noted by Juan Crespí be developed into a pueblo. The town was officially founded on September 4, 1781, by a group of forty-four settlers known as "Los Pobladores". Tradition has it that on this day they were escorted by four Spanish colonial soldiers, two priests from the Mission and Governor de Neve. The town was named El Pueblo de Nuestra Señora la Reina de los Ángeles del Río de Porciúncula (The Town of Our Lady the Queen of the Angels on the Porciúncula River). These pueblo settlers came from the common Hispanic culture that had emerged in northern Mexico among a racially mixed society. Two-thirds of the settlers were mestizo or mulatto, and therefore, had African, Amerindian, and European ancestry. More importantly, they were intermarrying. The settlement remained a small ranch town for decades, but by 1820 the population had increased to about 650 residents. Today, the pueblo is commemorated in the historic district of Los Angeles Pueblo Plaza and Olvera Street, the oldest part of Los Angeles.
New Spain achieved its independence from the Spanish Empire in 1821, and the pueblo continued as a part of Mexico. During Mexican rule, Governor Pío Pico, made Los Angeles Alta California's regional capital. Mexican rule ended during the Mexican–American War: Americans took control from the Californios after a series of battles, culminating with the signing of the Treaty of Cahuenga on January 13, 1847.
Railroads arrived with the completion of the Southern Pacific line to Los Angeles in 1876. Oil was discovered in 1892, and by 1923 Los Angeles was producing one-quarter of the world's petroleum.
By 1900, the population had grown to more than 102,000 people, putting pressure on the city's water supply. 1913's completion of the Los Angeles Aqueduct, under the supervision of William Mulholland, assured the continued growth of the city.
In the 1920s, the movie and aviation industries flocked to Los Angeles, with continuing growth ensuring that the city suffered less during the Great Depression. In 1932, with population surpassing one million, the city hosted the Summer Olympics.
The post-war years saw an even greater boom, as urban sprawl expanded the city into the San Fernando Valley. In 1960, non-Hispanic whites made up 82% of the population of Los Angeles County. In 1969, Los Angeles became one of the birthplaces of the Internet, as the first ARPANET transmission was sent from theUniversity of California, Los Angeles (UCLA) to SRI in Menlo Park.
In 1984, the city hosted the Summer Olympic Games for the second time. Despite being boycotted by 14 Communist countries, the 1984 Olympics became the most financially successful in history, and only the second Olympics to turn a profit – the other being the 1932 Summer Olympics, also held in Los Angeles.
During the remaining decades of the 20th century, the city was plagued by increasing gang warfare, drug trades, and police corruption. Racial tensions erupted again in 1992 with the Rodney King controversy and the large-scale riots that followed the acquittal of his police attackers. In 1994, the 6.7Northridge earthquake shook the city, causing $12.5 billion in damage and 72 deaths.
Voters defeated efforts by the San Fernando Valley and Hollywood to secede from the city in 2002.
Gentrification and urban redevelopment have occurred in many parts of the city, most notably Hollywood, Koreatown, Silver Lake, Echo Park and Downtown.