A senior police officer said on Monday that top prosecutor Hisham Barakat and his bodyguards had been taken to hospital after their car was hit outside a military academy in the Heliopolis neighborhood of the Egyptian capital.
State news agency MENA said Barakat had suffered "light injuries" in the explosion.
A little-known group, calling themselves "Giza Popular Resistance" claimed responsibility for the bomb by posting a statement on their Facebook page. The group also uploaded photos which it claimed were from the attack.
Egypt's former interior minister Mohammed Ibrahim survived a similar attack in September 2013.
Monday's bombing followed calls from the "Islamic State" (IS) group's affiliate in Egypt for to carry out the attacks on judiciary after the hanging of six alleged militants.
Egypt's judges and officials has been increasingly targeted by Islamist militants in recent months.
The terrorists, who oppose the government of President Abdel Fattah al-Sisi, have launched a string of attacks, apparently in response to the hefty sentences handed down to Muslim Brotherhood members.
Since Islamist President Mohamed Morsi was overthrown by the military in 2013, Barakat has referred thousands of Islamists to trial, with hundreds then sentenced to death.
An Egyptian court also said on Monday that it would issue a ruling in the retrial of two Al Jazeera journalists on July 30. The two men were previously charged with aiding a terrorist organization in connection with the Muslim Brotherhood and sentenced to seven and 10 years in prison.
ksb/rc (Reuters, AFP, AP)