Prior to the Muslim conquest of Syria, Arab tribes, particularly the Banu Kalb settled around Emesa, ensuring its position as an important Yamani center.
The Byzantine emperor Heraclius abandoned the city—which served as his headquarters—after his army's defeat by the Rashidun Muslims under Caliph Umar ibn al-Khattab during the Battle of Yarmouk in southern Syria.
In 637 CE, the Rashidun army led by Khalid ibn al-Walid captured Emesa peacefully because its inhabitants agreed to pay a substantial ransom of 71,000 to 170,000 dinars.
The caliph Umar established Homs as the capital of Jund Hims, a district of the province of Bilad al-Sham, encompassing the towns of Latakia, Jableh, and Tartus along the coast, Palmyra in the Syrian Desert and the territory in between, including the town of Hama.
Homs was likely the first city in Syria to have a substantial Muslim population.

The Muslims transformed half of St. John's Church into the city's Friday Mosque (Great Mosque of al-Nuri) and Homs soon became a centre of Islamic piety since some 500 companions of Muhammad settled there after its conquest.
The tombs of Khalid ibn al-Walid, his son Abd al-Rahman, and Ubayd Allah, the son of Caliph Umar are located in the city.
During the conflict between the Umayyads and Ali, the inhabitants of Homs allied themselves with Ali and when the latter was defeated, the Umayyad caliph Mu'awiyah hived the northern half of Jund Hims to form a separate district, Jund Qinnasrin, apparently as punishment.
Ali's oratory (mash-had 'Ali) was located in the city, and Islamic tradition claims his fingerprints are engraved on it.
Despite repression by the Umayyads, Homs remained a center of Shia Islam for a while longer.
As a stronghold of the Banu Kalb, the city became involved in the latter's conflicts with the Qays tribal faction.
The last Umayyad caliph, Marwan II, enjoyed the support of the Qais and subsequently razed the city walls in response to a rebellion by the Banu Kalb.

In 750 the Abbasids wrested control of Syria, including Homs, from the Umayyads, and the Arab tribes revolted.
Despite the prosperity Homs experienced during this era, Abbasid rule was generally not welcomed nevertheless.
During and after the reign of Caliph Harun al-Rashid (796–809), the Abbasid authorities sent numerous punitive expeditions against Homs.
Under the reign of Caliph al-Mutawakkil, in October 855, the Christian population revolted in response to additional taxation.
The caliph put down the revolt by expelling Christians from the city, burning down their churches and executing members of their leadership.

With Abbasid rule over the Caliphate weakening in the mid-9th century, Homs became sought after by rebel dynasties contending for control of Syria due to the city's strategic position.
Initially, the Egypt-based Tulunids came into control of it, but they were forced out by the Aleppo-based Hamdanids, who were briefly succeeded by the Qarmatians, after the latter's Turkish rebel ally Aftakin invaded northern Syria and established Homs as his base.
In 891 Muslim geographer al-Yaqubi noted that Homs was situated along a broad river which served as a source of drinking water for the inhabitants.
It was one of the largest cities in Syria and had several smaller districts surrounding it.
In 944 the Hamdanids took definitive control of the city, dominating it until 1016.
Arab geographer al-Mas'udi claimed in the early 10th century that Homs was "noted for the personal beauty of its inhabitants."
In 985 al-Muqaddasi noted that Homs was the largest city in all of Syria, but it had suffered "great misfortunes" and was "threatened with ruin."
He stated that when the city was conquered by the Muslims they turned half of its church into a mosque.

For around thirty years during the 10th century, Homs was raided by the Byzantines and its inhabitants were subject to slaughter and plunder while the city's mosque was briefly restored as a church.
Throughout most of the 11th century, the Byzantine raids receded greatly and the Mirdasids of the Banu Kilab tribe ruled over Homs, repl
Prior to the Muslim conquest of Syria, Arab tribes, particularly the Banu Kalb settled around Emesa, ensuring its position as an important Yamani center. The Byzantine emperor Heraclius abandoned the city—which served as his headquarters—after his army's defeat by the Rashidun Muslims under Caliph Umar ibn al-Khattab during the Battle of Yarmouk in southern Syria. In 637 CE, the Rashidun army led by Khalid ibn al-Walid captured Emesa peacefully because its inhabitants agreed to pay a substantial ransom of 71,000 to 170,000 dinars. The caliph Umar established Homs as the capital of Jund Hims, a district of the province of Bilad al-Sham, encompassing the towns of Latakia, Jableh, and Tartus along the coast, Palmyra in the Syrian Desert and the territory in between, including the town of Hama. Homs was likely the first city in Syria to have a substantial Muslim population.
The Muslims transformed half of St. John's Church into the city's Friday Mosque (Great Mosque of al-Nuri) and Homs soon became a centre of Islamic piety since some 500 companions of Muhammad settled there after its conquest. The tombs of Khalid ibn al-Walid, his son Abd al-Rahman, and Ubayd Allah, the son of Caliph Umar are located in the city. During the conflict between the Umayyads and Ali, the inhabitants of Homs allied themselves with Ali and when the latter was defeated, the Umayyad caliph Mu'awiyah hived the northern half of Jund Hims to form a separate district, Jund Qinnasrin, apparently as punishment. Ali's oratory (mash-had 'Ali) was located in the city, and Islamic tradition claims his fingerprints are engraved on it. Despite repression by the Umayyads, Homs remained a center of Shia Islam for a while longer. As a stronghold of the Banu Kalb, the city became involved in the latter's conflicts with the Qays tribal faction. The last Umayyad caliph, Marwan II, enjoyed the support of the Qais and subsequently razed the city walls in response to a rebellion by the Banu Kalb.
In 750 the Abbasids wrested control of Syria, including Homs, from the Umayyads, and the Arab tribes revolted. Despite the prosperity Homs experienced during this era, Abbasid rule was generally not welcomed nevertheless. During and after the reign of Caliph Harun al-Rashid (796–809), the Abbasid authorities sent numerous punitive expeditions against Homs. Under the reign of Caliph al-Mutawakkil, in October 855, the Christian population revolted in response to additional taxation. The caliph put down the revolt by expelling Christians from the city, burning down their churches and executing members of their leadership.
With Abbasid rule over the Caliphate weakening in the mid-9th century, Homs became sought after by rebel dynasties contending for control of Syria due to the city's strategic position. Initially, the Egypt-based Tulunids came into control of it, but they were forced out by the Aleppo-based Hamdanids, who were briefly succeeded by the Qarmatians, after the latter's Turkish rebel ally Aftakin invaded northern Syria and established Homs as his base. In 891 Muslim geographer al-Yaqubi noted that Homs was situated along a broad river which served as a source of drinking water for the inhabitants. It was one of the largest cities in Syria and had several smaller districts surrounding it. In 944 the Hamdanids took definitive control of the city, dominating it until 1016. Arab geographer al-Mas'udi claimed in the early 10th century that Homs was "noted for the personal beauty of its inhabitants." In 985 al-Muqaddasi noted that Homs was the largest city in all of Syria, but it had suffered "great misfortunes" and was "threatened with ruin." He stated that when the city was conquered by the Muslims they turned half of its church into a mosque.
For around thirty years during the 10th century, Homs was raided by the Byzantines and its inhabitants were subject to slaughter and plunder while the city's mosque was briefly restored as a church. Throughout most of the 11th century, the Byzantine raids receded greatly and the Mirdasids of the Banu Kilab tribe ruled over Homs, repl
Homs