KABUL, Afghanistan — When the White House ordered American diplomats this summer to engage the Taliban directly in the hopes of jump-starting an Afghan peace process, many in Afghanistan welcomed it as a vital first step in trying to break the stalemate that dominates the 17-year war here.
Publicly, President Ashraf Ghani was among them, projecting a measured tone. But officials say that in private, the Afghan leader repeatedly expressed concern and resistance to American officials about the prospect of talks that did not include his government.
They say his concern was that such talks, which the Taliban have insisted should not include the Afghan government, could become a fatal marginalization of the country’s leadership at a hazardous moment.
Last week, Mr. Ghani’s fears came true, in a humiliating way that he had worked to avoid.
The American special envoy, Zalmay Khalilzad, just days after hearing the Mr. Ghani’s concerns in Kabul, the Afghan capital, flew to the gulf state of Qatar and quietly met with Taliban representatives. Mr. Ghani and his government heard of that meeting only through news reports, and found out further details not through his American allies — even after he asked — but through a Taliban statement, according to several officials with detailed knowledge of the developments.
Those officials spoke on condition of anonymity because they were not authorized to brief the press about the discussions.
They described the Afghan president as furious at the breach of trust between allies, just months before a presidential vote in which he will seek a second term. In a meeting in Kabul the day after Mr. Khalilzad met the Taliban, according to the officials, Mr. Ghani specifically asked the American delegation about their talks with the Taliban but was not given any details — and the American envoy then changed the subject.
The immediate diplomatic blowback was not clear, but similar mistrust in the past has derailed previous attempts toward talks. Former President Hamid Karzai frequently denounced American officials as being duplicitous on several fronts, including communication with the Taliban.
One American official, also speaking on condition of anonymity, said that after the episode, Mr. Ghani had reached out to the American ambassador in Kabul, John Bass, and to Gen. Austin S. Miller, the commander of American forces in Afghanistan, to ensure he was not being cut out of the talks. They both assured him he was not, the official said.
Officials at the American Embassy in Kabul would not comment about the meetings, nor would Mr. Khalilzad.
Haroon Chakhansuri, a spokesman for Mr. Ghani, emphasized that their government “has been owning and leading the peace process,” including recent efforts like a rare cease-fire honored by the Taliban in June and the Kabul Process conference in February where Mr. Ghani explained his offer of peace.
Mr. Chakhansuri would not address specifics, but added, “Adherence of our partners and allies to this principle is the only path to a lasting peace in Afghanistan.”
In the history of episodic efforts to get talks going with the Taliban, coordination between American and Afghan officials has often been a delicate thing.
“Regrettably, the issue of the U.S. directly negotiating with the Taliban has always been viewed by our leaders as suspicious, unhelpful and an infringement of Afghan ownership of the peace effort,” said Jawed Ludin, a former deputy Afghan foreign minister. “But frankly, U.S. role in the peace effort is not only justified, given its huge stake in the conflict, but also necessary, especially when the Taliban insist that they are only ready to talk to Americans.”
“Having said that,” he added, “for this to be helpful to Afghanistan and the cause of peace, there must be total transparency and trust between the U.S. and Afghanistan. Otherwise it won’t succeed.”
Mr. Ghani fears that further marginalization of his coalition government, which is already under heavy pressure from a brutal insurgency and the political opposition, would put it at more risk of falling apart. Many are worried that the morale of the Afghan security forces, who are already sustaining heavy casualties as the Taliban gain ground, could suffer further.
But it was also a personal affront. Mr. Ghani lived in the United States for decades, and at great cost he has prioritized the relationship with Washington during his term. His rivals in the political opposition often describe him as an American yes-man, and he is said to be distrusted in neighboring countries like Iran and Russia because of his closeness to the United States.
One of the earliest attempts at peace by Afghan leaders just days into the American invasion in 2001, when the desperate Taliban were ready to surrender in return for safety, was publicly quashed by the defense secretary at the time, Donald Rumsfeld.
Years later, distrust between former President Karzai and American officials blew up when an effort to bring the Taliban into negotiations seemed to be bringing results, with the opening of a Taliban political office in Qatar. Despite American assurances, Mr. Karzai feared the Taliban would turn the opportunity into a publicity coup. He was right: The Taliban flew their flag over the office and posted a sign declaring it the “Political Office of the Islamic Emirate of Afghanistan,” the Taliban government’s name when it ran Afghanistan.
This year, President Trump’s weariness with the costly war has injected a sense of urgency into efforts to bring the Taliban to the table, even though it has meant giving in to the insurgents’ demand to only talk to the Americans.
American diplomats met once with the Taliban over the summer. Then, last month, Mr. Khalilzad, the former American ambassador to Iraq and the United Nations, was tasked as American special envoy to push for Afghan reconciliation.
Mr. Khalilzad commands considerable clout in Afghanistan, where he served as President George W. Bush’s ambassador and envoy during the early years of the war. At a time when the Afghan government was still finding its feet, the American ambassador played a central role in governing.
In his new role, Mr. Khalilzad made his first trip to the region earlier this month. After meetings in Kabul, Pakistan and Saudi Arabia, he arrived in Qatar last Friday, where he met with a delegation of Taliban representatives, officials said.
The next morning, he landed in Kabul for an apparent discussion with the Afghan president about the results of his travels. Before the meeting began, Mr. Ghani’s office was already getting questions from the press about whether the Americans had met with the Taliban. His office was unaware of the details, officials said.
Mr. Khalilzad, in his opening remarks over cake and tea, was said to have made no mention of seeing the Taliban. When Mr. Ghani mentioned the news media’s questions, Mr. Khalilzad did not give a clear answer. One official with knowledge of the discussion said the response had sounded like a denial, while a second official said the envoy was awkwardly trying to evade the subject.
At some point in the meeting, an irritated Mr. Ghani was handed a note by an aide telling him that a Wall Street Journal article about the meetingwas already out. Officials said that Mr. Khalilzad said he had read that story but criticized the sourcing of it, before moving the conversation to other topics. The Afghan delegation did not probe further.
Just a couple hours after the meeting, the Taliban put out a detailed statement confirming they had met Mr. Khalilzad’s delegation in Doha, Qatar, and that both sides agreed to continue such engagements.
One Afghan official informed of Mr. Khalilzad’s travels also said the American envoy met with a separate group of Taliban in Dubai, though the timing and other details of that meeting were unclear, and it could not be independently confirmed.