The former foreign secretary Boris Johnson had vowed to leave no stone unturned in his efforts to persuade the Iranian government to release Nazanin Zaghari-Ratcliffe. It is not yet clear whether his successor Jeremy Hunt found a face-down stone that Johnson had somehow missed or instead a confluence of new forces has prompted her temporary reprieve.

The UK ambassador in Tehran, Rob Macaire, had been given little warning of her release and she herself was given only a few minutes’ notice.

The release can be seen either as a welcoming gift to the incoming Hunt, a reward for specific recent diplomatic gestures made by the UK, or an indicator of the extent to which Iran, under massive US sanctions pressures, needs all the friends it can find in Europe. It is quite possible all three factors played a role in the often opaque thinking inside Tehran’s dual regime. A visit to Tehran by the UK Foreign Office permanent secretary, Sir Simon McDonald, in late July may also have been pivotal.

Play Video 0:39 Nazanin Zaghari-Ratcliffe: husband hopeful of full release – video

Since his appointment, Hunt had made the Zaghari-Ratcliffe file a priority, meeting her husband Richard twice for lengthy discussions, describing his sympathy as the father of young children from a mixed race marriage.

Hunt did not leap to escalate the crisis in a way that would have offended Iran by giving her diplomatic protection, a status the Zaghari-Ratcliffe family have been seeking from the Foreign Office for many months.

He went out of his way via McDonald to assure the Iranians that his elevation to the foreign secretaryship would not lead to any change to the UK’s support for the Iranian nuclear deal, the linchpin of Iranian diplomacy. Donald Trump pulled the US out of the deal in April.

Indeed, Hunt signed a joint statement with France and Germany on 6 August, the day the first round of US anti-Tehran sanctions kicked in, defending the deal as “a key element of the global nuclear non-proliferation architecture, crucial for the security of Europe, the region, and the entire world”.

Macaire, days after presenting his own credentials as ambassador to Iran’s president, Hassan Rouhani, tweeted the statement saying “its message could not be clearer”.

US ready to drive Iranian oil exports to zero, says US national security adviser Read more

In interviews surrounding his visit this week to Washington, and in his encounter with US secretary of state, Mike Pompeo, Hunt stood his ground, insisting excessive US pressure on Tehran was only likely to lead to a regime more hostile to the west. In this, he was diverging from the US on its pre-eminent foreign policy issue, a point that McDonald hammered home in his Tehran visit.

But the UK has also been making some quiet gestures of goodwill towards Iran. For example, the Iranian embassy in London has been allowed to open a bank account.

The head of the Atomic Energy Organization of Iran (AEOI), Ali Akbar Salehi, this week highlighted how the UK – jointly with China – had assumed responsibility for helping Iran rebuild its heavy water reactor in Arak. The UK involvement, volunteered at a meeting with Iranian officials in Vienna in July, is designed to reduce the amount of plutonium produced by the reactor as a by-product, so ensuring Iran remains inside the terms of the deal. The additional UK cooperation came after US technical experts pulled out.

Facebook Twitter Pinterest Iran’s president Hassan Rouhani. Photograph: Lisi Niesner/Reuters

There have also been tentative signs of progress on the single biggest blockage in the bilateral relationship – the UK’s refusal to repay £450m outstanding debt on a 40-year-old arms deal, because of a dispute over the interest rate on the debt and the difficulty of making a payment that is not in breach of international sanctions.

Tehran suggested in recent weeks that the payment need not be made in cash but in kind through medicines, so circumventing sanctions. A sympathetic British response could end a diplomatic sore that began in 2002 and has resulted in successive court judgements against the UK.

Finally, Iran has come to accept that the EU is sincere in trying to soften the impact of US secondary sanctions on EU firms active in Iran.

Tehran always saw the nuclear deal as a simple trade-off. It would hold off on restarting the nuclear programme so long as the lifting of sanctions led to a substantial rise in western investment.

The difficulty has been that EU multinationals, faced with a choice between investing in Iran, and as a consequence facing US Treasury sanctions on its often larger US outlets, are choosing Washington over Tehran. The dollar still rules. An EU €18m package of aid to Iran announced by Brussels on Thursday hardly fills the blight on European investment caused by the US sanctions threat.

Nazanin Zaghari-Ratcliffe freed from Iran jail temporarily Read more

The EU’s efforts to prevent an exodus from Iran has not worked, as firm after firm has announced it was abandoning planned investments. The British Airways announcement on Thursday that it was suspending its uncommercial service to Tehran symbolises how hopes of a business revival have been disappointed.

British officials say it is not widely understood how the US has chosen sanctions policy, and the dominance of the dollar, as an instrument with which to impose its foreign policy rule on Europe. In Brussels, Berlin and Paris, it has prompted an anguished debate about how the intrusiveness of secondary sanctions is exposing the lack of true European economic and foreign policy sovereignty.

Tehran may have realised that, given the geopolitical stakes ahead, anything standing in the way of the support of the UK’s newforeign secretary was worth re-examining.