Former Iranian president Akbar Hashemi Rafsanjani died on Sunday at the age of 82, state media reported, a big blow to moderates and reformists deprived now of their most influential supporter in the Islamic establishment.
"Ayatollah Hashemi Rafsanjani was taken to hospital after heart attack and more than an hour long efforts by doctors to revive him were not successful," the deputy minister of health was quoted by Fars news agency as saying.
Residents said a crowd gathered outside the hospital in northern Tehran where Rafsanjani was taken.
In a sign of mourning, state television channels carried a black banner on a corner of screen.
Mehdi, the imprisoned son of Hashemi who is in jail on corruption charges, attended the hospital to say goodbye to the body of his father. He was escorted out by police.
Rafsanjani was an influential figure in Iran, and headed the Expediency Council, a body which is intended to resolve disputes between the parliament and the Guardian Council. He was also a member of the Assembly of Experts, the clerical body that selects the supreme leader, Iran's most powerful figure.
Rafsanjani has been described as "a pillar of the Islamic revolution." His pragmatic policies — economic liberalization, better relations with the West and empowering Iran's elected bodies — appealed to many Iranians but was despised by hardliners.
His death is a big blow to moderate president Hassan Rouhani five months before a presidential election.
Since 2009 he and his family have faced criticism over their support for the opposition movement which lost that year's disputed election to former president Mahmoud Ahmadinejad.
His funeral will be held in Tehran on Tuesday, his relative and aide Hossein Marashi was quoted as saying by Fars news agency.