EIGHTEEN MONTHS after President Obama ordered a surge of U.S. troops into Afghanistan, there is general agreement on one point: The campaign has been a tactical military success and has reversed the Taliban’s momentum. There has been progress, too, in expanding and training the Afghan army, which is due next month to take over lead security responsibility in seven provinces and cities with a quarter of the country’s population.

However, as Mr. Obama and his commanders frequently say, the progress is “fragile and reversible.” NATO must beat back an ongoing Taliban counteroffensive; it must expand its military clearing operations from the south to the still- enemy-infested east. The job of constructing a viable Afghan government mostly remains to be done. Meanwhile, attempts to broker a political settlement with the Taliban or establish a regional diplomatic framework that could support such a deal have barely begun.

What all that means is that next month is not a logical or appropriate moment for the United States to begin a troop withdrawal — whether small, medium or large. That such a pullout will nevertheless take place is the result of Mr. Obama’s imprudent decision to set a date for the beginning of withdrawals at the same time he ordered the surge of troops. The president and his advisers are now debating, in private and increasingly in public, how large the withdrawal should be. The process has reopened a split between those who believe in the strategy of building an Afghan government and army that can hold a diminished Taliban at bay by 2014, and those who would narrow U.S. aims to preventing al-Qaeda from reestablishing a base in the region.

A larger withdrawal this year — the 15,000 troops suggested by some in Congress, for example — would shove the United States in the latter direction. It would make it hard, if not impossible, to extend or even sustain military gains against the Taliban, while sending its leaders — and their sponsors in Pakistan — the message that there is no need to make concessions to a rapidly retreating force. Its advocates argue that the death of Osama bin Laden and diminishment of al-Qaeda make further large-scale operations in Afghanistan unnecessary; that the Afghan government and army are a lost cause; or that the United States can no longer afford the $2 billion a week being spent on the war.

That last argument is particularly shortsighted: The marginal billions that might be gained from withdrawing more troops now will have no significant impact on a deficit problem measured in trillions — while the loss of Afghanistan to extremist forces would impose huge costs on the United States. It is premature to claim that the effort to build the Afghan government is futile; it would seem prudent to see how well the government does in taking over its first provinces and cities before making a judgment. Similarly, it is too soon to know whether the elimination of Osama bin Laden will have any effect on the Taliban or its willingness to break with al-Qaeda.

Mr. Obama’s July pullout date seemed driven more by domestic political considerations than sound strategy — and his argument that it would push the Afghan government to step up proved faulty. Some reports suggest that proposals driven by similar calculations are under consideration — such as setting the fall of 2012 as a date for withdrawing all 30,000 of the surge troops. We hope that the president will not repeat the mistake of publicly setting withdrawal dates. Instead, he should bet on sustaining the gains his strategy has achieved — by minimizing this summer’s pullout.