Uprising
Károlyi traveled to Vienna to negotiate with Imperial ministers over what he and other nobles deemed excessive taxation, conscription, and extraction of war contributions; his wife remained at the family estate. Imperial commanders threatened her with county-wide devastation unless she provided war contributions; she refused, and the Habsburg garrison of the family's primary fortress surrendered without consulting her or their Hungarian commanders. Károlyi's wife and daughter (Klára) were evicted from their home. On his return trip to his home, town after town controlled by Imperial War office refused him lodging. After a series of attempts to recover his property, locate his family, and complete negotiations for fairer extractions, he was pushed into rebellion with several other Hungarian nobles.
The Habsburg forces, fully engaged in the lengthy War of the Spanish Succession, did not have the additional military power to engage the nobles, but the Hungarian leadership had neither the financial resources nor the military ones, to defeat the Habsburg forces in Hungary. Throughout 1703–1706, the former Habsburg general wrought havoc in Moravia and Bohemia. The ongoing insurrection, in which Sándor Károlyi played a significant part, led to the deposition of the Habsburg king in Hungary in 1707. However, after victories at Blenheim and Turin, the Habsburgs were able to devote more resources against recalcitrant Hungarians. The uprising took a dramatic turn at the Battle of Trencsén, on 4 August 1708. Rákóczi was knocked off his horse; his troops thought he had been killed, and fled. Rákóczi fled to Poland.