Jerusalem in the Middle Ages was a major Byzantine metropolis from the 4th century CE before the advent on the early Islamic period in the 7th century saw it become the regional capital of Jund Filastin under successive caliphates. In the later Islamic period it went on to experience a period of more contested ownership, war and decline. Muslim rule was interrupted for a period of about 200 years by the Crusades and the establishment of the Christian Kingdom of Jerusalem. At the tail end of the Medieval period, the city was ceded to the Ottomans in 1517, who maintained control of it until the British took it in 1917.
Jerusalem prospered during both the Byzantine period and in the early time period, but under the rule of the Fatimid caliphate beginning in the late 10th century saw its population decrease from about 200,000 to less than half that number by the time of the Christian conquest in 1099. The siege of Jerusalem by the Crusaders saw much of the extant population at the time massacred as the Christian invaders took the city, and while its population quickly recovered during the Kingdom of Jerusalem, its population was decimated to less than 2,000 people when the Khwarezmi Turks took the city in 1244. The city remained a backwater under the Ayyubids, Mameluks and Ottomans, and would not again exceed a population of 10,000 until the 16th century.[1]