The blast followed a deadly truck explosion on Wednesday near the presidential palace and foreign embassies, which killed nearly 100 people and wounded almost 500 others.
The number of casualties on Saturday was not immediately clear, but local news media reported that at least a dozen people had been killed. A high death toll was feared because the blast occurred just as a large crowd was standing for the funeral prayer.
After the blast, mourners began running from the hill, where the body of Salem Izidyar, the son of the deputy speaker of the senate, was to be buried.
Mr. Izidyar was one of at least six people killed on Friday, after protests reaching the gates of the Afghan presidential palace turned bloody and security forces opened fire to disperse the crowd.
Protesters were calling for the resignation of the government for its failure to stop the truck bombing on Wednesday.