A genetic fingerprint study has provided strong evidence of the MRSA ­superbug spreading from farm animals to hospitals and baby clinics in the UK.

Scientists identified three samples of the drug-resistant bacteria from a hospital and neonatal unit in the west of Scotland that closely matched a specific strain found in livestock.

Generally, people and animals harbour different forms of the potent MRSA strain CC398 investigated by the researchers. However, the new evidence suggests the livestock version has found its way into hospitals.

Study leader Dr Melissa Ward, from Edinburgh University, said: "Our ­findings emphasise the need for strict biosecurity practices in the food production industry, as well as continued surveillance and infection control of MRSA in hospitals."

MRSA is a serious hazard in healthcare settings. The CC398 strain can cause life-­threatening infections.

Dr Ward's team unravelled the genetic codes of British CC398 samples and compared them with data on the same bugs from humans and livestock around the world.

The most significant evidence of animal-to-human transmission came from sequences of MRSA collected in Scotland. Two were from samples taken six months apart from a neonatal ward in Greater Glasgow and Clyde. The third was from a cleaning project at a Glasgow hospital.

Writing in the journal Applied and Environmental Microbiology, the scientists concluded: "It is possible that this finding represents the persistence of the livestock-associated strain of CC398 in hospital settings in the UK, with onward transmission between humans"