In Transylvania Basta's army persecuted Protestants and illegally expropriated their estates until Stephen Bocskay (1605-07), a former Habsburg supporter, mustered an army that expelled the imperial forces. In 1606 Bocskay concluded treaties with the Habsburgs and the Turks that secured his position as prince of Transylvania, guaranteed religious freedom, and broadened Transylvania's independence. After Bocskay's death and the reign of the tyrant Gabriel Báthory (1607-13), the Porte compelled the Transylvanians to accept Gábor Bethlen (1613-29) as prince. Transylvania experienced a golden age under Bethlen's enlightened despotism. He promoted agriculture, trade, and industry, sank new mines, sent students abroad to Protestant universities, and prohibited landlords from denying an education to children of serfs. After Bethlen died, however, the Transylvanian Diet abolished most of his reforms. Soon György Rákóczi I (1630-40) became prince. Rákóczi, like Bethlen, sent Transylvanian forces to fight with the Protestants in the Thirty Years' War; and Transylvania gained mention as a sovereign state in the Peace of Westphalia. Transylvania's golden age ended after György Rákóczi II (1648-60) launched an ill-fated attack on Poland without the prior approval of the Porte or Transylvania's Diet. A Turkish and Tatar army routed Rákóczi's forces and seized Transylvania. For the remainder of its independence, Transylvania suffered a series of feckless and distracted leaders, and throughout the seventeenth century Transylvania's Romanian peasants lingered in poverty and ignorance.
During Michael the Brave's brief tenure and the early years of Turkish suzerainty, the distribution of land in Walachia and Moldavia changed dramatically. Over the years, Walachian and Moldavian princes made land grants to loyal boyars in exchange for military service so that by the seventeenth century hardly any land was left. Boyars in search of wealth began encroaching on peasant land and their military allegiance to the prince weakened. As a result, serfdom spread, successful boyars became more courtiers than warriors, and an intermediary class of impoverished lesser nobles developed. Would-be princes were forced to raise enormous sums to bribe their way to power, and peasant life grew more miserable as taxes and exactions increased. Any prince wishing to improve the peasants' lot risked a financial shortfall that could enable rivals to out-bribe him at the Porte and usurp his position.
In 1632 Matei Basarab (1632-54) became the last of Walachia's predominant family to take the throne; two years later, Vasile Lupu (1634-53), a man of Albanian descent, became prince of Moldavia. The jealousies and ambitions of Matei and Vasile sapped the strength of both principalities at a time when the Porte's power began to wane. Coveting the richer Walachian throne, Vasile attacked Matei, but the latter's forces routed the Moldavians, and a group of Moldavian boyars ousted Vasile. Both Matei and Vasile were enlightened rulers, who provided liberal endowments to religion and the arts, established printing presses, and published religious books and legal codes.