In 1923, Khoja Niyaz returned to Xinjiang, first to Ghulja, then to Urumchi, where he was involved in organizing underground revolutionary groups and preparing a new rebellion.
In 1927, he returned to Kumul for the funeral of his father, and after the death of Kumul Khanate ruler Shah Mahsut in March 1930, Hoja Niyaz was appointed to the high position of adviser to new ruler of the Kumul Khanate.

Nevertheless, the Xinjiang Governor Jin Shuren (1928–1933), sought to take advantage of the power vacuum left after the death of Shah Mahsut and decreed the abolition of the Kumul Khanate, preventing the new ruler, Shah Mahsut's son Nazir, from assuming control.
At the same time, Jin Shuren arranged for Han Chinese migrants from Gansu to settle in the abolished Khanate.
These events sparked the Kumul Rebellion in 1931, which was led by Hui warlord Ma Chung-ying in Gansu after his June 1931 meeting with Hoja Niyaz and Yulbars Khan.
Ma Chung-ying agreed to add his troops to the campaign to topple Jin Shuren.
Hoja Niyaz also received support from the Mongolian People's Republic: in autumn 1931 they provided him 600 sets of winter clothes, felt tents and 120 rifles (which were actually bartered for horses, one rifle was given for two horses).

Rebellion soon spread from the East of Xinjiang throughout the whole province and by February, 1933, when Urumqi was laid siege by joint Uyghur and Hui troops, the Provincial Government controlled no more than 10% of Xinjiang's territory.
On April 12, 1933, General Sheng Shicai came to power in Xinjiang after former Governor Jin Shuren was toppled off in March by the mutinied Russian Cossack troops ( retreated to Northern Xinjiang in 1921 after losing civil war in Russia), who previously were mobilized by Jin Shuren into Provincial Army in late 1931 in desperate attempt to quell Rebellion.
Sheng Shicai gained support from USSR after confirming all secret agreements that previous Governor concluded with the Soviet Union and in June 1933 he made an alliance with Hoja Niyaz against Ma Chung-ying.
Previous alliance between Hoja Niyaz and Ma Chung-ying was destroyed following the battle of Jimsar.
On this battle Hoja-Niyaz forces suffered heavy casualties, but forced garrison of Jimsar to surrender.
Ma Chung-ying forces during the battle guarded mostly the flanks and the back of joint troops, while Uyghur troops were put into the frontal attack on Jimsar fortress.
Hoja-Niyaz agreed to provide the free retreat of besieged garrison in exchange of weapons of the fortress' Arsenal.
But at night, Ma Chung-ying suddenly came to the fortress, seized all Arsenal (12,000 rifles, 6 machine guns and 500,000 bullets) and joined Chinese garrison to his Tungan troops.
He refused to share weapons of the seized Arsenal with Hoja-Niyaz, that outraged the latter.
This happened on May 28, 1933 and on the next few days Hoja-Niyaz already met with the representatives of Soviet Consul-General in Urumchi Apressoff to start peaceful talks with Sheng Shicai.
Agreement of alliance between Sheng Shicaii and Hoja-Niyaz was signed on June 4, 1933 and at this time the Soviets gave Hoja Niyaz "nearly 2,000 rifles with ammunition, a few hundred bombs and three machine guns."
The newly appointed Soviet Consul in Urumqi, Garegin Apresoff, who arranged negotiations, forced Hoja Niyaz to turn his troops against Tungans (Hui) forces, and that eventually led to the rebellion's turning into massacres between different national groups, and its defeat in the hands of Provincial troops.

Hoja Niyaz marched his troops across Dawan Ch'eng to Toksun, where he was defeated at the Battle of Toksun by Tungans under General Ma Shih-ming.
Hoja Niyaz then fell back to Kashgar on January 13, 1934, retreating from Aksu through a 300 miles-long march by Tengri Tagh mountain road along the Soviet/Chinese border, bypassing this way general Ma Fuyuan's Tungan forces who waited him on the main road from Aksu to Kashgar, and assumed the Presidency of the self-proclaimed Turkish Islamic Republic of Eastern Turkestan or First East Turkestan Republic.
Joining t
In 1923, Khoja Niyaz returned to Xinjiang, first to Ghulja, then to Urumchi, where he was involved in organizing underground revolutionary groups and preparing a new rebellion. In 1927, he returned to Kumul for the funeral of his father, and after the death of Kumul Khanate ruler Shah Mahsut in March 1930, Hoja Niyaz was appointed to the high position of adviser to new ruler of the Kumul Khanate.
Nevertheless, the Xinjiang Governor Jin Shuren (1928–1933), sought to take advantage of the power vacuum left after the death of Shah Mahsut and decreed the abolition of the Kumul Khanate, preventing the new ruler, Shah Mahsut's son Nazir, from assuming control. At the same time, Jin Shuren arranged for Han Chinese migrants from Gansu to settle in the abolished Khanate. These events sparked the Kumul Rebellion in 1931, which was led by Hui warlord Ma Chung-ying in Gansu after his June 1931 meeting with Hoja Niyaz and Yulbars Khan. Ma Chung-ying agreed to add his troops to the campaign to topple Jin Shuren. Hoja Niyaz also received support from the Mongolian People's Republic: in autumn 1931 they provided him 600 sets of winter clothes, felt tents and 120 rifles (which were actually bartered for horses, one rifle was given for two horses).
Rebellion soon spread from the East of Xinjiang throughout the whole province and by February, 1933, when Urumqi was laid siege by joint Uyghur and Hui troops, the Provincial Government controlled no more than 10% of Xinjiang's territory. On April 12, 1933, General Sheng Shicai came to power in Xinjiang after former Governor Jin Shuren was toppled off in March by the mutinied Russian Cossack troops ( retreated to Northern Xinjiang in 1921 after losing civil war in Russia), who previously were mobilized by Jin Shuren into Provincial Army in late 1931 in desperate attempt to quell Rebellion. Sheng Shicai gained support from USSR after confirming all secret agreements that previous Governor concluded with the Soviet Union and in June 1933 he made an alliance with Hoja Niyaz against Ma Chung-ying. Previous alliance between Hoja Niyaz and Ma Chung-ying was destroyed following the battle of Jimsar. On this battle Hoja-Niyaz forces suffered heavy casualties, but forced garrison of Jimsar to surrender. Ma Chung-ying forces during the battle guarded mostly the flanks and the back of joint troops, while Uyghur troops were put into the frontal attack on Jimsar fortress. Hoja-Niyaz agreed to provide the free retreat of besieged garrison in exchange of weapons of the fortress' Arsenal. But at night, Ma Chung-ying suddenly came to the fortress, seized all Arsenal (12,000 rifles, 6 machine guns and 500,000 bullets) and joined Chinese garrison to his Tungan troops. He refused to share weapons of the seized Arsenal with Hoja-Niyaz, that outraged the latter. This happened on May 28, 1933 and on the next few days Hoja-Niyaz already met with the representatives of Soviet Consul-General in Urumchi Apressoff to start peaceful talks with Sheng Shicai. Agreement of alliance between Sheng Shicaii and Hoja-Niyaz was signed on June 4, 1933 and at this time the Soviets gave Hoja Niyaz "nearly 2,000 rifles with ammunition, a few hundred bombs and three machine guns." The newly appointed Soviet Consul in Urumqi, Garegin Apresoff, who arranged negotiations, forced Hoja Niyaz to turn his troops against Tungans (Hui) forces, and that eventually led to the rebellion's turning into massacres between different national groups, and its defeat in the hands of Provincial troops.
Hoja Niyaz marched his troops across Dawan Ch'eng to Toksun, where he was defeated at the Battle of Toksun by Tungans under General Ma Shih-ming. Hoja Niyaz then fell back to Kashgar on January 13, 1934, retreating from Aksu through a 300 miles-long march by Tengri Tagh mountain road along the Soviet/Chinese border, bypassing this way general Ma Fuyuan's Tungan forces who waited him on the main road from Aksu to Kashgar, and assumed the Presidency of the self-proclaimed Turkish Islamic Republic of Eastern Turkestan or First East Turkestan Republic. Joining t
Khoja Niyaz