Cairo — A U.S. citizen who went on a hunger strike and claimed he was wrongfully imprisoned in Egypt died after spending six years behind bars, the State Department said.

Mustafa Kassem, 54, an Egyptian-born auto parts dealer from Long Island, New York, died of heart failure after a hunger strike he began last year to protest his unjust incarceration, his lawyers said.

A photo purported by Egyptian media to show U.S. national Mustafa Kassem, who has died on hunger strike after six years in an Egyptian prison.

"His death in custody was needless, tragic and avoidable," Assistant Secretary of State for Near Eastern Affairs David Schenker told reporters. "I will continue to raise our serious concerns about human rights and Americans detained in Egypt at every opportunity."

Get Breaking News Delivered to Your Inbox

Egypt's chief prosecutor ordered an autopsy and investigation into Kassem's medical condition, and confirmed Tuesday that he had been transferred from the prison to Cairo University hospital, where he died.

Kassem was in Cairo to visit family in August 2013 when, his lawyers say, he was mistakenly swept up in a vast dragnet during the violent breakup of an Islamist sit-in that killed hundreds of people. That summer, security forces descended on supporters of ousted President Mohammed Morsi, who hails from the Muslim Brotherhood, in what became known as the "Rabaa Massacre."

Kassem was exchanging money at a shopping mall near Cairo's Rabaa al-Adawiya Square when police stopped him and asked to see identification. When he handed over his U.S. passport, officers suddenly started beating him, and detained him. He was held for five years before he was charged.

Then in 2018, in a mass trial of over 700 defendants widely condemned by human rights organizations, Kassem was sentenced to 15 years under a contentious anti-protest law. After that, he refused to eat anything but vegetable juice, his lawyers said. Last week, he stopped even drinking.

When President Trump secured the release of Egyptian-American rights advocate Aya Hijazi, who was imprisoned for three years in Egypt on false charges, Kassem appealed to the U.S. administration for help. Vice President Pence raised the issue last year with Egyptian President Abdel Fattah el-Sissi.

El-Sissi came to power the same summer of 2013 and has overseen a sweeping crackdown on dissent, silencing critics and jailing thousands. Rights groups accuse Egyptian prosecutors of detaining people without evidence, denying them access to lawyers and a fair chance to appeal.

"It's a scary precedent," Hijazi, who pressed for Kassem's release, told The Associated Press. "Both for what it means for the many political prisoners on hunger strike in Egypt right now ... but also for imprisoned U.S. citizens that have called on American authorities to respond, to no avail."

Hijazi said Kassem was the fifth person to die in an Egyptian prison over the past month.

"He was targeted not because he was a criminal, but because he was American," she added, speaking about his arrest and imprisonment.

The death of Kassem, who suffered from diabetes, has also prompted accusations of medical negligence by activists, who say authorities restricted his access to much-needed medication during years of detention.

Kassem's case evoked that of Morsi, who was also held in the same notorious Tora prison. The divisive but democratically-elected Morsi died last year while on trial in a Cairo courtroom, six years after his overthrow amid mass protests against his rule.

U.N. experts recently said that "brutal" prison conditions, as well as deprivation of vital diabetes medicine, contributed to Morsi's death.