The mood in Erbil, Sulaymaniyah and Dohuk - the three largest cities in Iraqi Kurdistan - is newly buoyant these days, and with good reason. Iraq's Kurds, who occupy the semiautonomous region run by the Kurdistan Regional Government (KRG), have much to celebrate.

They enjoy relative peace and stability compared with the rest of the country, boast a moderately open society, and, over the past year, have received a whopping vote of confidence in their nascent economy from some of the world's largest oil companies, including ExxonMobil, Chevron, Total and Gazprom, all of which have signed exploration contracts with the KRG. Not only is Iraqi Kurdistan undergoing an unprecedented building boom, but its people are now articulating a once-unthinkable notion: that the day they will break free from the rest of Iraq is nigh.

As the Kurds press forward, they are growing increasingly estranged from the government of Iraqi Prime Minister Nouri al-Maliki; personal relations between Maliki and the Kurdish regional president, MassoudBarzani, have reached an all-time low, keeping them from resolving critical disputes over power, territory, and resources. This past June, Barzani and other opponents of Maliki tried to oust the prime minister through a vote of no confidence, and although they failed to do so, their ambition remains very much alive.

The Kurds are victims of history, geography and, on the occasions they overreach, their own ambitions. For almost a century, they have struggled to free themselves from central control and to overcome their landlocked location. Today, a rapidly changing region is presenting them with new allies and fresh opportunities. Yet there is good reason to believe that the Kurds will have to defer their quest for statehood once again, at most trading Baghdad's suffocating embrace for a more amenable dependence on Turkey.

Although Ankara has long supported Iraq's territorial unity as a barrier against Iranian influence and as a check against secessionist impulses among its own Kurdish population, the government of Turkish Prime Minister Recep Tayyip Erdogan has recently begun to shift strategies. Since 2008, it has forged a close economic bond with the KRG by opening its border and encouraging Turkish investments in the Kurdish region, and its relations with Baghdad have deteriorated due to Maliki's authoritarian turn and the growing perception in Ankara that Maliki is serving as a proxy for Iran.

The question is how far Turkish leaders will go -- whether they will be prepared to abandon their Plan A, reinforcing a unified Iraq, for Plan B, linking up with entities estranged from Baghdad, such as the Kurds and the largely Sunni provinces in northern Iraq, at the risk of breaking up Iraq. Already, the rhetoric in Ankara has changed. Officials no longer refer to Iraq's unity as a sine qua non; now, it is a "preference." And Erdogan is said to have promised Barzani that Turkish forces will protect the Kurdish region in the event of a military assault from Baghdad. Even if the unannounced visit that Turkish Foreign Minister Ahmet Davutoglu made to the contested city of Kirkuk in August wasn't meant to signal support for the Kurds' territorial claims in Iraq, Baghdad's furious reaction showed that it was received that way.

Maliki has announced plans to establish a new military headquarters in Kirkuk, and there are other unsettling signs of the city's growing militarization. Barzani, for his part, is offering Turkey powerful incentives to turn away from Baghdad: a regular flow of more than one million barrels of oil a day through a set of direct pipelines now under construction, a stable Sunni Kurdish buffer on Turkey's southeastern border against Maliki's Shiite-dominated government and the KRG's help in blocking Kurdish rebels from expanding into Kurdish areas of Syria.

For Turkey, however, the risks of throwing its support behind Iraq's Kurds would be enormous. A disintegrating Iraq would strengthen Iran's quest for regional dominance, and an independent Iraqi Kurdistan would further empower Turkey's own Kurdish minority. Turkish leaders face a serious dilemma. They cannot predict the outcome of the crisis in Syria or to what extent Kurds throughout the four countries they inhabit will be empowered by it. Yet Turkey urgently needs access to Iraq's energy resources, and as long as its relations with Baghdad remain in the doldrums, Ankara appears ready to buy oil directly from the Kurds without a green light from the Maliki government.

Such a move would help the Kurdish region gain more autonomy from Baghdad and give it leverage over Ankara. It will not, however, produce a state. In the end, the Kurds will remain stuck in Iraq, but more and more on their own terms. Given their troubled history, this is serious progress, and it offers a foundation on which to build something even better.