Ebrahim Yazdi, an Iranian political activist and American-trained cancer researcher who became one of Ayatollah Ruhollah Khomeini’s top confidants, only to emerge as a prominent dissident against an Islamic revolutionary regime he found increasingly using “Stalinist and un-Islamic methods,” died Aug. 27 in Izmir, Turkey. He was 85.

The cause was pancreatic cancer, said his niece Roya Yazdi.

Dr. Yazdi, who once described himself to the New York Times as a “modernist intellectual Muslim,” spent decades as one of the few outspoken dissidents largely allowed to go about his business under the repressive revolutionary government. His seemingly protected status stemmed from his closeness to the revered Khomeini, although his clout dwindled significantly over the past two decades, and he was frequently jailed and harassed.

He was a microbiology student at the University of Tehran when he became swept up in the nationalist fervor that elected Mohammad Mosaddegh as prime minister. He was radicalized by the 1953 U.S.-backed coup that deposed Mosaddegh and restored to power the pro-Western Shah Mohammad Reza Pahlavi, who ran the country with an increasingly ­autocratic hand over the next 26 years.

Dr. Yazdi joined the fledgling opposition party known as the Freedom Movement of Iran and belonged to underground groups that aimed to overthrow the shah, which led to his arrest and beatings by the Savak secret police. Persona non grata under the shah, he moved to the United States in the early 1960s, taught pharmacy at Fairleigh Dickinson University in New Jersey and became a U.S. citizen.

Ebrahim Yazdi, once Iran's foreign minister, flashes the victory sign, as he arrives in 2005 at the Interior Ministry, to register as a presidential candidate in Tehran. (Vahid Salemi/AP)

He settled in Houston at Baylor University’s medical school, where he worked as a researcher and a professor, and received a doctorate in biochemistry. Colleagues described him to reporters as pleasant and hard-working, and they were surprised when he suddenly emerged as a figure of international significance after the Islamic revolution toppled the shah and his corrupt government in 1979.

Over the previous few years, Dr. Yazdi had become a close adviser to the exiled cleric Khomeini, a guiding force behind the revolution. After the cleric had been expelled from Iraq, Dr. Yazdi helped establish a new headquarters for Khomeini near Paris in 1978 in the run-up to his triumphant return to Tehran, where he promised a religious form of governance that was harmonious with republican ideals.

Dr. Yazdi, now a leader in the FMI, helped sell that view of moderation to the Western world. Although ardently anti-Zionist, he said he wanted an Iran that had a free market, constitutional elections and stable relations with the West while also holding true to Islamic values. He was convinced that the ayatollah had a place for moderates in his government, including FMI founder Mehdi ­Bazargan.

Dr. Yazdi served as foreign minister and deputy prime minister for revolutionary affairs for the interim government under Khomeini’s Islamic Republic. In the bloody chaos of those first few months, he reportedly tried to halt summary executions by firing squad of dozens of imprisoned sympathizers of the shah. He explained that the former regime fell too fast and revolutionaries were ill-equipped to run the penal system, so executions commenced to prevent a coup by the Savak.

The situation on the streets remained explosive, with a raging anti-Americanism after the United States gave safe passage to the ailing shah. Threatening crowds massed at the U.S. Embassy in Tehran, and Dr. Yazdi, whose American citizenship was revoked, gave public reassurances that the occupants would be safe.

Then, on Nov. 4, 1979, militants seized the compound and took more than 50 people hostage, triggering an international crisis that lasted 14 months. Khomeini’s explicit approval of the kidnapping disabused Dr. Yazdi of the ayatollah’s intentions. The clergy soon sidelined moderate revolutionaries such as Bazargan on the road to forming an Islamic theocracy under the rule of a supreme ­leader.

“They thought they were using the clergy, but the clergy was using them,” Mehdi Khalaji, a senior fellow at the Washington Institute for Near East Policy, said of moderates such as Dr. Yazdi. “He was one of the most controversial figures in Iran. Hard-liners and anti-regime elements say he paved the way for the Islamic Republic. You would hear very extreme statements on both sides, which shows his legacy would remain mixed.”

1 of 66 Full Screen Autoplay Close Skip Ad × Notable deaths so far this year View Photos Remembering those who have died in 2017. Caption Remembering those who died in 2017. Mamie “Peanut” Johnson Mamie “Peanut” Johnson, the first female pitcher in the Negro leagues, died on Dec. 18. Read the obituary: Mamie ‘Peanut’ Johnson, hard-throwing woman in baseball’s Negro leagues, dies at 82 Katherine Frey/The Washington Post Buy Photo Wait 1 second to continue.

After resigning from Khomeini’s cabinet, Dr. Yazdi remained in parliament for a few years. Bazargan died in 1995, and Dr. Yazdi succeeded him at the helm of the FMI, which was officially illegal and had little political clout to champion its goals of democratic reform. When Dr. Yazdi made a bid for the presidency in 2005, he was disqualified by the official election watchdog council, along with other pro-reform candidates.

Dr. Yazdi was outspoken against hard-line President Mahmoud Ahmadinejad’s reelection in 2009 amid street protests over accusations of widespread voter fraud. Dr. Yazdi was detained that year and released from prison in 2011, soon after he reputedly agreed to step down as FMI leader. Months later, the country’s Revolutionary Court sentenced him to eight years in prison for allegedly acting against national security interests.

Dr. Yazdi served less than a year in prison but remained under house arrest in Tehran, his niece said. He was allowed to seek treatment in Turkey as his health ­deteriorated.

The son of a prosperous merchant, Dr. Yazdi was born in ­Qazvin in northwest Iran, on Sept. 26, 1931.

Survivors include his wife, the former Sourour Talieh of Tehran; six children, Khalil Yazdi of Fredericksburg, Va., Sarah Yazdi of Harrisburg, Pa., Lily Yazdi of Izmir, Youseph Yazdi of Ellicott City, Md., Mary Yazdi of Ann Arbor, Mich., and Iman Yazdi of Seattle; 16 grandchildren; and a great-grandchild.

Khomeini died in 1989, and Ayatollah Ali Khamenei was named supreme religious leader. When Dr. Yazdi was arrested in 1997 on specious charges, it was widely seen as a test of powers between deeply conservative and reformist players in government.

“This chapter of our history, the revolutionary chapter, is not concluded,” he told the Times that year. “Nobody can say for sure what will be the conclusion of the 1979 revolution. I don’t have a date, but this will be a democratic society sooner or later.”

He was asked if he thought he was safe expressing such views. “Not very much, but we feel this is our country,” he said, “and no one can claim to be more revolutionary or Islamic than I am. I stay inside the country in order to say these things.”