In 1768, the Javad Khan,
Hasan Khan Shahseven voluntarily accepted the suzerainty of the Quba Khanate. However, khan power was kept in Javad. This event, along with the enlargement of the territory of the Quba Khanate, also influenced the dynamics of its population. Historical sources point out that the Javad Khanate's voluntary association to the Quba Khanate has a positive effect on the quantity and quality of its population. The population of the
Mughan plain was able to live in a stable political environment in the 1760s and 1780s. The sources (which was kept in books and archives) to uncover the Javad Khanate's population history are fragmentary and limited. Hidayat Khan's 1778 invasion significantly impacted the demographics of the Mughan Plain and Javad city. The khan of the Javad Khanate, which was peacefully related to the Quba Khanate, soon became one of the closest men to
Fatali Khan. The khan of Javad was one of the most trusted men of Fatali Khan and participated in his secret meetings. The merging of Mughan, both military and strategic, meant further strengthening of the Quba khanate. The rivals of Fatali Khan could not adopt a policy of diplomatic maneuvering among the great powers (
Russia,
Qajars,
Ottomans). The combination of Fatali Khan and the Mughan plains and Javad Khanate in their lands did not correspond to the interests of a number of the khanates. The fact that the majority of Mughan plain, under the control of Fatali Khan, was a traditional winter grazing area for the aforementioned khanates, as well as the transfer of a part of Ardebil and the Mughan peoples to the Quba Khanate did not correspond to the interests of Gilan, Ardabil, Garadagh and the other khanates. A number of southern khanates, formerly engaged in diplomatic experimentation against the Quba Khanate, engaged in military intervention shortly after the defeat of Fatali Khan in 1774 in
Gavdushan. Hidayat Khan of Gilan was particularly interested in this work. He united with the former
Aghasi Khan of Shirvan and Garagaytag. The troops of the Hidayat Khan went to Javad, the center of Javad Khanate, after robbing of
Lankaran and Salyan in 1778. In April 1778, after the attack on Javad city, the inhabitants panicked. Hasan Khan felt he failed to stand up against his powerful opponents. Taking his brother and son (Khan of Gilan), he went to the camp of Hidayat Khan. According to some, 900 people were relocated from the city. While other sources mention 7,500 people were relocated from the city. They were driven to
Rasht and
Anzali to perform heavy work such as tower construction and agricultural work. This incident had a negative impact on the historical demographics of the Javad Khanate. The city of Javad was destroyed and did not return to its former situation. In 1781, Hasan Khan's troops united with the khans of Quba, Derbent, Baku, Shirvan, Shaki, Karabakh, Lankaran and Ardabil against
Agha Mohammad Khan Qajar, the candidate for the Iranian throne. In 1783, Hasan Khan attacked Karabakh as part of the 13,000-strong army of Fatali Khan. Fatali Khan attacked
Ardabil and
Meshkin in May 1784. The emirates of
Shahsevan followed him. Hasan Khan was appointed ruler of Ardabil. == Political geography ==