Police said they had been travelling in a vehicle to meet President Ashraf Ghani, who is visiting Nangarhar province, when the bomber struck.
Among those killed was the only Sikh candidate who had planned to contest October’s parliamentary elections.
The Islamic State (IS) group said it carried out the attack.
Hours earlier, Mr Ghani had opened a hospital in Jalalabad during his two-day visit to Nangarhar. Officials said he was not in the area when the suicide blast occurred.
The Indian embassy in Kabul condemned the “cowardly terrorist” attack.
It confirmed that Awtar Singh Khalsa, the only Sikh candidate running in the 20 October elections, was among the dead.
“The attack underlines the need for a united global fight against international terrorism without discrimination and accountability of those who support terrorists in any manner,” the embassy tweeted.
Nangarhar health director Najibullah Kamawal told AFP news agency that 17 of the dead were Sikhs and Hindus. Another 20 people were wounded, he added.
The bomber targeted the vehicle as it passed through Mukhaberat square in the city, governor’s spokesman Attaullah Khogyani said. The explosion badly damaged shops and buildings.
Small communities of Sikhs and Hindus live in Afghanistan which is otherwise an overwhelmingly Muslim nation.
Correspondents say increasing numbers have moved to India due to persecution and repeated threats.
IS said on its Amaq news agency that it had carried out the attack although it gave no evidence for the claim.
The latest attack comes after last month’s three-day ceasefire between government forces and the Taliban.
The brief truce did not include IS which is fighting both the Taliban and government forces.