When Afghan President Ashraf Ghani took over in late 2014 and talk of peace and reconciliation with the Taliban gained momentum, skeptics derived hope from China's newfound interest in the process.
China could succeed, many thought, where the United States had failed — in convincing Pakistan to change its behavior toward the Afghan Taliban. Both the U.S. and Afghanistan accuse Pakistan of providing a safe haven to the Afghan Taliban. Pakistan has so far resisted any pressure.
At the heart of Chinese interest in stability in Afghanistan are two major factors. One is fear that religious militancy in Afghanistan will further fuel Islamist insurgency in China's own Xinjiang province bordering Afghanistan. Militants from the Uighur Muslim minority in Xinjiang have occasionally received support and training in Afghanistan.
The second is hope of extending the One Belt, One Road initiative through the region to Central Asia.
The initiative is an effort by China to build a network of overland road and rail routes, oil and gas pipelines, and other infrastructure projects spanning from West China through Central Asia to Europe while simultaneously developing ports and coastal infrastructure through South and Southeast Asia all the way to the Mediterranean.
What China can do
It may be difficult to precisely measure the kind of influence China can exercise, according to Dr. Hassan Askari Rizvi, a Lahore-based political analyst.
FILE - Delegations from Afghanistan, Pakistan, the United States of America and China discuss a road map for ending the war with the Taliban at the Presidential Palace in Kabul, Afghanistan, Jan. 18, 2016.
The conflicts between Afghanistan and Pakistan, he said, are so inherent that China cannot force them to change. All it can do is encourage the two rivals to downplay them.
China is a new player at this table. For the first 15 years of the war in Afghanistan, it stayed out of security arena, focusing more on economic interests. Now its economic interests have become intertwined with regional security. So it has joined the game, but is still in the learning stage.
China is more likely to watch and wait rather than act prematurely, according to Kabul-based analyst Hamed Sabori.
Still, Khalid Mahmood, one of Pakistan's former ambassadors to China, thinks the country is ideally placed to play the role of mediator between Afghanistan and Pakistan.
"[China] commanded respect in Afghanistan, had good ties to Pakistan, and regional stability was in its own interest," according to Mahmood.
China initiated contacts with the Taliban and eventually agreed to become part of the Quadrilateral Coordination Group (QCG), set up to help facilitate reconciliation talks between the Taliban and the Afghan government.
The initial U.S.-Afghan euphoria with Chinese involvement has slightly worn off.
The QCG failed to lead to a decrease in violence in Afghanistan. Both Afghans and Americans realized that China would not pressure Pakistan beyond a certain point. With the killing of Taliban leader Mullah Mansoor and the election of new leader Mullah Hibatullah Akhundzada, chances of peace talks this year are grimmer than ever.
FILE - Pakistani local residents gather around a burning vehicle hit by a U.S. drone strike, May 21, 2016. Afghan Taliban Mullah Akhtar Mansoor was the target of the drone near Dalbandin, Baluchistan, Pakistan.
"I don't believe that we will see peace talks anytime in the short term," said Brig. Gen. Charles Cleveland, deputy chief of staff for communications for Operation Resolute Support, the NATO mission in Afghanistan.
Analyst Rizvi thinks the Chinese approach has been more measured because it recognizes the limits of Pakistan's capacity to influence the Afghan Taliban.
Plus, China has a strong alliance with Pakistan, made even stronger by the U.S. courting of Pakistan's rival India as a regional counterweight to China.
"They [the U.S.] have clearly stated which side they are on, which country they want to raise as [a] counterweight to China … which has implications for Pakistan also," Mahmood said.
In the eyes of many Pakistanis, including many in the civilian and military leadership of the country, the U.S. does not care about Pakistan's interests and does not keep in mind its sensibilities when dealing with the region. Mahmood said that drives the country more toward China, which is viewed as a tried and tested friend.
Nonetheless, China sees stability in the region as being in its own long-term interest. Shahmahmood Miakhel, the country head for the Washington-based United States Institute for Peace, said China has made significant investments in Afghanistan, particularly in the mining sector. These are not short- or medium-term investments, he added, but long-term ones that require a secure regional environment.
Which was why Afghanistan is still pinning its hopes on China.
"China has to work with Pakistan on how to cooperate with Afghanistan," Miakhel said.
China, Sabori said, is waiting to see how the U.S. and other major players are going to act. Still, it is aware of the danger of continued long-term instability.
"Terrorism is not something that can be confined to a border, so it will finally, at some time, penetrate their border and it will become a major issue for China," he said.