Egyptian Prosecutor General Hisham Barakat has been killed in a bomb attack on his car in Cairo, officials say.
Hisham Barakat died of his wounds in hospital after the bombing in the suburb of Heliopolis.
According to state media, at least eight others were also hurt in the attack.
Hisham Barakat has referred thousands of Islamists to trial since the overthrow of President Mohamed Morsi in 2013.
Hundreds of Islamists have been sentenced to death or life imprisonment, as part of a crackdown on supporters of the banned Muslim Brotherhood.
Hisham Barakat is the most senior figure to have been targeted for assassination since a 2013 attempt on the life of the then-interior minister.
“He [Hisham Barakat] has passed away,” Justice Minister Ahmed al-Zind told AFP news agency.
The Egyptian state news agency Mena said that he had died after undergoing critical surgery. A medical official at the hospital told the Associated Press that Hisham Barakat had received multiple shrapnel wounds to the shoulder, chest and liver.
The attack involved a car bomb or an explosive device placed under a parked car near Hisham Barakat’s convoy, bomb squad chief Gen. Mohamed Gamal told AFP.
The explosion sent black smoke rising over the neighborhood and set fire to nearby trees. Images from the scene showed several damaged vehicles and bloodstains on the streets.
At least three civilians were killed, according to Mena. Witnesses said that the blast had been strong enough to shatter the windows of nearby homes.
At the hospital, an injured bodyguard said that the explosion had hit Hisham Barakat’s convoy on the way to the office.
“There was glass flying everywhere. It was as if there was an earthquake,” he said, according to AFP.
Hisham Barakat had received death threats in the past.
The Egyptian affiliate of the Islamic State militant group (ISIS) recently called for attacks on the judiciary, after the hanging of six militants.