In a televised speech on Sunday, Ghani said that Afghans had to decide their fate, not outside powers, even if they were allies.
“Our future cannot be decided outside, whether in the capital cities of our friends or neighbors. The fate of Afghanistan will be decided here in Afghanistan,” he said.
The president said that peace was only possible with an agreement between the Afghan government and the Taliban.
“Peace is a desire for each Afghan, and peace will come, there shouldn’t be any doubt about it,” Ghani said. “But we want a peace in which each Afghan has dignity. We don’t want a peace in which Afghans wouldn’t have dignity. We don’t want a peace that would cause our people to leave their country.”
The Kabul government is left out of the talks between the US and the Taliban, which have been going on in Qatar.
Elsewhere in the speech, Ghani referred to the upcoming presidential election and said that “without a legitimate and strong government that comes through an election, Afghans won’t be able to achieve a dignified peace.”
A presidential election is scheduled for September 28, in which Ghani hopes to win a second term.
Some US officials have hinted at the possibility that the presidential poll could be canceled in the event of a settlement and the formation of an interim government that the Taliban would join.
The militant group, which now controls or has influence in about half of Afghanistan’s territory, has held several rounds of direct talks with US officials in the Qatari capital since October. The militants say they don’t recognize the government in Kabul.
The ongoing talks come nearly 18 years after the US military invaded Afghanistan to overthrow a ruling Taliban regime.
About 20,000 foreign troops, mostly Americans, are based in Afghanistan.
The exit of foreign troops from Afghanistan is a condition set by the Taliban to extend the talks.