NHSX was contacted about the potential for Apple and Google’s API’s to “break” its version of the contact-tracing app in April, it has been revealed.

Michael Veale, a lecturer in digital rights at University College London, contacted the organisation on 11 April to flag that Apple and Google’s new API only allows decentralised matching between devices.

This would leave many Androids and iPhones incompatible with the NHS centralised contact-tracing app.

Publishing his email to NHSX on Twitter, Veale confirmed representatives from the organisation had responded to his concerns.

The email states: “Apple and Google’s new API appears to break (or rather, not allow iPhones of Androids to use) NHS’s proposed system, as it only allows decentralised local matching using background BLE [Bluetooth], and does not allow apps to directly access identifiers of individuals they have observed, only to query them with a downloaded list.”

Veale said he presumed this would require a “rewrite” of the NHSX app to align it with the APIs or “all uses with newer Androids or iPhones will require the screen to be on when it is in their pocket”.

He added that would “not be necessary” if NHSX shifted its architecture of the app.

NHSX faced fierce criticism over its decision to pursue a centralised contact-tracing app, which would see data collected from individual devices sent to a central server.

Privacy experts and campaigners suggested a decentralised version, like Apple and Google’s APIs, offered greater data security and less risk of mission creep. But a decentralised systems means epidemiologists have less access to data.

Despite concerns about privacy, NHSX launched a trial of its contact-tracing app on the Isle of Wight in the first week of May, after Veale’s concerns were flagged.

After weeks of silence on the outcome of the trial and expected national roll-out date, the government announced on 18 June it was abandoning its version of the app and switching to Apple and Google’s technology in a major U-turn.

The government would begin working with the tech giants to develop a companion app that supports the “end-to-end” NHS test and trace service, shifting from a centralised to a decentralised app.

Neither version of the technology proved fit for purpose, according to Baroness Dido Harding, chair of the test and trace service.

Field tests on both revealed the NHSX version was able to register about 75% of nearby Android devices, but just 4% of iPhones. The Apple and Google model was more accurate, logging 99% of Android devices and iPhones, but had difficulty measuring the distance between users’ devices.

A contact-tracing app won’t be successful if it’s unable to accurately measure distance and duration of contacts.

To date the NHS contact-tracing app has cost £11.8 million. Lord Bethell, the parliamentary under-secretary of state for innovation confirmed the figure in a House of Lords sitting on 22 June.

He said the decision to switch to Apple and Google’s model was “operational”, noting there had been “technical issues” with both systems.

A Department of Health and Social Care spokesperson said: “We were absolutely right to invest in the Isle of Wight phase – it has provided us with valuable information that we will now use to build an app that is right for the British public.

“Our rigorous testing identified issues both with our app and the Google/Apple API, which did not estimate distance in the way we required. So if we had simply followed their approach we would be no further towards building a viable product.

“We are now working on a solution that brings together what we have learned as we develop a new version of an app to support the entire NHS test and trace service.”

NHSX has been contacted for comment.

Blame game

Health secretary Matt Hancock has criticised Apple over the failure of the NHS contact-tracing app to work on iPhones.

Speaking on Sky News’s Sophy Ridge programme he accused the tech giant of “intransigence” and suggested Apple refused to make the change to allow the NHS version of the app to work.

“Of course I wish we had brought it in sooner, I wish that Apple had made the change for it to work in Apple phones in the same way that the original works on Android phones, but we will get there,” he said.

Developers have been working on the NHSX contact-tracing app and on Apple and Google’s technology since early May, he confirmed during the coronavirus news briefing at Downing Street on 18 June.

Apple has been contacted for comment.