The city of Baghdad (Arabic: بغداد Baġdād) was founded in the mid 8th century as the Abbasid capital, following the Abbasid victory over the Umayyad Caliphate. It replaced the Sassanid capital of Seleucia-Ctesiphon some 35 km to the south-east, which was mostly depopulated by the end of the 8th century. Baghdad was the center of the Arab caliphate during the "Golden Age of Islam" of the 9th and 10th centuries, growing to be the largest city worldwide by the beginning of the 10th century. It began to decline in the 10th century, and was destroyed in the Mongol invasions, in 1258.
The city was rebuilt and flourished under Ilkhanid rule but never rose to its former glory again. It was again sacked by Timur in 1401 and fell under Turkic rule. It was briefly taken by Safavid Persia in 1508, before falling to the Ottoman Empire in 1534. With the dissolution of the Ottoman Empire, Baghdad fell under the British Mandate in 1920 and became the capital of the independent Kingdom of Iraq in 1932 (converted to a Republic in 1958).
As the capital of the modern Republic of Iraq, Baghdad has a metropolitan area estimated at a population of 7,000,000, divided into numerous neighbourhoods in nine districts. It is the largest city in Iraq. It is the second-largest city in the Arab world (after Cairo) and the second-largest city in Southwest Asia (after Tehran). In recent history, Baghdad has been affected by the Iraqi civil war, most notably by recurring bombings.