Egypt's former President Mohamed Morsi died after appearing in court in Cairo, Egyptian state media reported on Monday.
Morsi, who was toppled from power by the military in 2013, died after fainting in a courtroom in the nation’s capital Cairo.
Morsi who was a top figure in the now-banned Muslim Brotherhood, collapsed in a cage after speaking at a hearing on charges of espionage.
According to Egyptian officials, the ex president had a history of health issues, including diabetes and liver and kidney disease.
He had suffered from medical neglect during his imprisonment, compounded by the poor conditions in jail.
A judicial source meanwhile said that Morsi was speaking before the judge for several minutes then became very animated and fainted.
He was quickly rushed to the hospital where he later died," the sources said.
In reaction to Morsi’s demise, Human Rights Watch called the news of his death "terrible" but "entirely predictable", citing the government's "failure to allow him adequate medical care".
Morsi was Egypt's first democratically elected president.
He won general elections in 2012, one year after the Arab Spring uprising saw the end of President Hosni Mubarak's 30-year rule.
Morsi had been behind bars for nearly six years and was serving a 20-year prison sentence for a conviction arising from the killing of protesters during mass public protests in 2012. He was also serving a life sentence for espionage in a case related to the Gulf state of Qatar.