After the internal conflicts of the 19th century, Buenos Aires was federalised and removed from Buenos Aires Province in 1880; its city limits were enlarged to include the former towns of Belgrano and Flores; both are now
Argentines sometimes refer to the city as Capital Federal to differentiate the city from the province of the same name. In the 1994 constitution, the city was given autonomy, hence its formal name: Ciudad Autónoma de Buenos Aires.
The abbreviations Bs. As., Baires and B.A. are sometimes used, the first one mostly in writing and the latter two in everyday speech. The city is sometimes called La Reina del Plata, that is, "The Queen of the Plata" (a reference to the Plata river basin).
Portuguese seaman Juan Díaz de Solís, navigating in the name of Spain, was the first European to reach the Río de la Plata, in 1516, but his expedition was cut short by an attack in which he was killed by the native Charrúa or Guaraní tribe, in today's Uruguay.
The city was first established as Ciudad de Nuestra Señora Santa María del Buen Ayre (literally "City of Our Lady Saint Mary of the Fair Winds") on February 2, 1536 by a Spanish expedition under Pedro de Mendoza. The location of Mendoza's city was in today's San Telmo district, south of the city center.
More attacks by the indigenous peoples forced the settlers away, and in 1541 the site was abandoned. A second (and permanent) settlement was established in 1580 by Juan de Garay, who arrived by sailing down the Paraná River from Asunción (now the capital of Paraguay).
From its earliest days, the success of Buenos Aires depended on trade. During most of the 17th and 18th centuries, Spain insisted that all trade to Europe pass through Lima, Peru so that taxes could be collected. This scheme frustrated the traders of Buenos Aires, and a thriving contraband industry developed. Unsurprisingly, this also instilled a deep resentment in porteños towards Spanish authorities.
Sensing these feelings, Carlos III of Spain progressively eased the trade restrictions and finally declared Buenos Aires an open port in the late 1700s. Those placating actions did not have the desired effect, and the porteños, some of them versed in the ideology of the French revolution, became even more desirous of independence from Spain.
During the British invasions of the Río de la Plata British forces invaded Buenos Aires twice in 1806–1807 but were repulsed by local militias. Ultimately, on May 25, 1810, while Spain endured the Peninsular War and after a week of mostly pacific deliberations, the criollo citizens of Buenos Aires successfully ousted the Spanish Viceroy and established a provisional government. May 25 is now celebrated as a national holiday (May Revolution Day). Formal independence from Spain was declared only in 1816.
Historically, Buenos Aires has been Argentina's main centre for liberal and free-trade ideas, while many of the provinces, especially to the Northwest, advocated a more conservative-Catholic approach to political and social issues. Many tensions within Argentine history, starting with the centralist-federalist conflicts of the 19th century, can be traced back to these contrasting views.