With the defeat of the Sassanid state by Arab troops in the 1930s, the military-political situation in the region, including Azerbaijan, changed. In 639, the Arab army, which attacked Azerbaijan from the south, met with strong resistance. After winning the battle near the city of Ardabil, the Arabs signed a treaty in 644 with Isfandiyar, the frontier guard of the southern lands of Azerbaijan. According to the agreement, Azerbaijani lands became part of the Caliphate, the country had to pay land and life taxes, the Arabs promised not to touch their religious beliefs and customs, allowed those who wanted to leave the country, and those who wanted to serve in the Arab army were exempted from taxes for a year. In 639-642, the Arab armies faced strong resistance in Mugan and Shirvan, and in 646 in Aran, Beylagan and Barda, eventually winning and concluding similar agreements with local judges. With the end of the Mehrani dynasty in Albania in 705, the Arabs ended the occupation of Azerbaijan in the early eighth century. In the 20s and 30s of the 8th century, the Arab-Caspian wars for the lands of Azerbaijan ended with the victory of the Caliphate. According to the agreement, Azerbaijani lands became part of the Caliphate, the country had to pay land and life taxes, the Arabs promised not to touch their religious beliefs and customs, allowed those who wanted to leave the country, and those who wanted to serve in the Arab army were exempted from taxes for a year. In 639-642, the Arab armies faced strong resistance in Mugan and Shirvan, and in 646 in Aran, Beylagan and Barda, eventually winning and concluding similar agreements with local judges. With the end of the Mehrani dynasty in Albania in 705, the Arabs ended the occupation of Azerbaijan in the early eighth century. In the 20s and 30s of the 8th century, the Arab-Caspian wars for the lands of Azerbaijan ended with the victory of the Caliphate.
The Arabs spread Islam in the occupied territories. Before Islam, Zoroastrianism existed in the southern lands of Azerbaijan, and Christianity and paganism existed in Albania. The Arabs' slogans of Muslim equality and their lower taxes on the population than the Sassanids allowed Islam to spread in southern Azerbaijan for only a century. Zoroastrianism, the symbol of Sassanid power, had fallen out of favor, and the people accepted Zoroastrianism as a form of Sassanid oppression. When power in the caliphate passed from the Umayyads to the Abbasids in 750, the process of conversion to Islam in the lands south of the Araz River in Azerbaijan came to an end. The Arabs did not touch the religion of the Jews and Christians who worshiped the Torah and the Bible, but simply collected a "jizya" life tax from them. In Albania, the Christian church and the Christians of the Book were largely left untouched. However, the Arabs persecuted local feudal lords and church leaders, fearing that Albanian feudal lords and Albanian Catholicosia would establish ties with Byzantium.
The Arabs created a system of subordination-emirate rule in Azerbaijan. Before the Umayyads, the Arabs included Azerbaijan and Ara in the 4th Emirate, and in the time of the Umayyads, in the 3rd Emirate. Amir lived in the city of Dabil. During the Abbasid period, the center of the emirate was moved to Barda. During this period, the borders of Azerbaijan stretched from Derbent in the north to Hamadan in the south.
The Arabs pursued a policy of resettlement in Azerbaijan in order to strengthen themselves, gain support, Arabize and Muslimize the population. The Arab population was relocated from Syria, Kufa, Basra and other places and settled in Azerbaijan.
In 725/26, the population, land, livestock and all kinds of property were listed in Azerbaijan and Aran. In this case, although more attention was paid to the collection of taxes, additional taxes were imposed on the population. The demand for taxes in cash had completely depleted silver and gold in Azerbaijan. The tax census enslaved the people and the whole country, and in 727 there was a terrible famine.
During the reigns of Caliph al-Mansur (754-755) and Caliph Harun al-Rashid (786-809), taxes on the population of Azerbaijan and Ara were increased: 4 million dirhams a year were collected from the south of Azerbaijan and 300,000 dirhams from Mugan. The property of those who escaped tax evasion or moved to the city was appropriated by Arab and local nobles.