Barclays is not liable for the alleged sexual assault of more than 100 patients by a doctor carrying out medicals on the bank’s behalf, the supreme court has ruled.

The UK’s highest court overturned earlier rulings that the bank was “vicariously liable” for any assault proven to have been carried out by Dr Gordon Bates, who died in 2009 aged 83.

The test case arose out of a damages action brought by a group of 126 claimants, who cannot be named for legal reasons, who claimed they were assaulted by the doctor.

The issue examined was whether an employer was “liable for sexual assaults committed by a medical practitioner in the course of medical examinations carried out at the employer’s request, either before or during the claimant’s employment”.

The panel of five supreme court justices were unanimous in allowing the bank’s appeal, saying Bates was “a classic independent contractor” and the person engaging him was “not vicariously liable”.

The claimants, mostly women, were examined without chaperones between 1968 and 1984 by Bates at his home in Newcastle upon Tyne. The majority were pre-employment checks of prospective employees, with some patients as young as 16.

A police investigation, begun in 2012 three years after Bates’s death, concluded there would have been sufficient evidence to pursue a prosecution if he had not died.

Announcing the decision, via a livestream, the court’s president, Lord Reed, said: “It is of course most regrettable that these allegations did not come to light until after Dr Bates had died.”

“Nothing in this judgment seeks to deny or downplay the very serious harm which sexual abuse of the sort alleged against Dr Bates can do.But the relationship between Dr Bates and the bank was not such that the bank should be made to pay for it.”

A high court judge, ruling on the preliminary issue of liability in 2017, decided Barclays was “vicariously liable”. The court of appeal subsequently upheld this decision.

Reading the supreme court judgment, on behalf of his predecessor, Lady Hale, Reed said Bates was an independent contractor. The doctor carried out work for the NHS, conducted medical examinations for a range of clients and wrote a weekly newspaper article.

“An employee, or near-employee, is working in and for the employer’s business or enterprise. An independent contractor is working for his own business or enterprise,” the ruling said.

“Dr Bates was not an employee or anything close to an employee of the bank. He was in business on his own account as a medical practitioner, with a portfolio of patients and clients. The work for the bank was a very small proportion of his work.

“The bank made the appointments and sent him the form to fill in, but they paid him a fee for each report. They did not pay him a retainer. He could refuse to do a requested examination if he chose.

“He no doubt carried his own medical liability insurance (although this may not have covered deliberate wrongdoing of the sort alleged).In short, he was a classic independent contractor for whom the person engaging him is not vicariously liable”

A Barclays spokesperson said: “Barclays sympathises with all of the claimants in this case. We were very concerned to learn of the allegations in relation to Dr Bates. We take the welfare of all employees, including former employees, very seriously and therefore upon being made aware of these allegations we took steps to remind relevant former employees of the bank’s employee support helpline providing access to counselling services. These services remain available for anyone requiring ongoing support.”