A Dandie Dinmont Terrier will be recovering with the help of pet medication after being fitted with a pacemaker.
Angus, a two-year-old, was the first dog in Scotland to receive the operation after being diagnosed with a third-degree heart block.
The condition means that he has a particularly slow heartbeat that could have been life-threatening.
Vet cardiologists Craig Devine and Yolanda Martinez Perriera carried out the operation and Angus is now recovering in hospital.
Ms Martinez Perriera said: “This dog had a very, very slow heart beat – only about 40-50 beats per minute - which didn’t change when he exercised.
“This could be life-threatening, so we decided he needed a pacemaker, which will regulate his heart beat and help him to function normally.”
The first clinical implantation of a pacemaker into a human was in 1958 in Sweden. The world’s first pacemaker patient was Arne Larsson, who died in 2001 at the age of 86.