Ayatollah Mohammad Yazdi, 83, headed the judiciary for 10 years and was a deputy speaker of parliament after the 1979 Islamic revolution.
He gained 47 of the 73 votes cast at a closed-door meeting in Tehran, according to the website of state television, citing officials.
Yazdi was among five contenders whose names had been linked to the post by Iranian media in recent weeks but he was not the most talked about.
His election represents a heavy defeat for former president Akbar Hashemi Rafsanjani, a relative moderate who previously held the position between 2007 and 2011, and who received 24 votes.
More From This Section
Comprised of 86 religious figures elected by the people, the Assembly of Experts chooses the Iran's supreme leader and monitors his actions.
The clerical body grants the leader, currently Ayatollah Ali Khamenei, an indefinite term but it retains the power to sack him, if it sees fit.
Although Rafsanjani put his name forward, he had appeared reluctant about resuming the post, insisting his membership of Iran's top political arbitration body, the Expediency Council, already kept him busy.
"We'll see on the day. My criterion is that it should be someone who befits the stature of the Assembly of Experts.