A suicide attack inside on a mosque at a military base in Khost province in Afghanistan killed at least 26 people and wounded 50 others, the military said.
Captain Abdullah, a spokesman for the Afghan National Army, said the explosion happened during Friday prayers when attendance is higher than usual.
The Afghan news channel Tolo said those killed were all from the 2nd Regiment of Afghan National Army in Mandozai district.
Investigations continued to determine the type of explosion.
The attack happened two days after a suicide blast killed dozens in Kabul during a religious ceremony.
Security in Afghanistan has steadily deteriorated, with the United Nations Assistance Mission in Afghanistan (UNAMA) recording the highest number of civilians killed and wounded, almost 1700, between January and June this year. This month, President Ashraf Ghani revealed that nearly 30,000 Afghan security personnel have been killed since the beginning of 2015, when Afghans took over the responsibility of securing the country from NATO.
The United States is trying to jump-start negotiations with the Taliban to help find a road map to peace. U.S. Special Envoy Zalmay Khalilzad was in the region for more than a week this month. He met Taliban representatives in Doha, Qatar, as well as various factions of Afghan society.
Talking to media, Khalilzad said he was "cautiously optimistic" about the chances of progress.
"I think there is an opportunity for reconciliation and peace," he said.
President Donald Trump said that his administration was involved in "very strong" peace negotiations in Afghanistan. However, he did not indicate whether he was hopeful of their success.