He was born in August 1815 the eldest son of Hector Gavin (1784-1874), an engraver at 150 High Street on the Royal Mile in Edinburgh's Old Town. His mother was Marion Walker (b.1795). The family home was destroyed in the Great Fire of Edinburgh in 1824 and they moved to 8 North Bridge before going to the characterful Croft-an-Righ next to Holyrood Palace, the home of his late grandfather.
He was educated in Edinburgh then studied Medicine at Edinburgh University specialising in Military Surgery, winning a prize in a government-sponsored contest for the best essay on feigned diseases. He moved to London in 1836 and gained his doctorate (MD) there in 1838. In Lodon he worked variously at the London Orphan Asylum, the British Penitent Female Refuge, and the Bethnal Green Workhouse. During this time he also lectured in Forensic Medicine and Public Hygiene at Charing Cross Hospital.
He was the author of several publications, including Sanitary Ramblings.
He was also the editor of the Journal of Public Health, and Lecturer on Forensic Medicine at Charing-cross Hospital. ... In 1849, during the cholera, he was employed as medical superintending inspector under the General Board of Health. ... During the epidemic of 1854, he was appointed by Lord Canning physician to the Post Office, which position he held until his last fatal mission.
At the request of Lord Palmerston and Lord Panmure, Gavin with Dr. John Sutherland and Robert Rawlinson headed a Sanitary Commission sent to the Crimean War to improve sanitation in the war hospitals. The Sanitary Commission members arrived in March 1855
However, on 21 April 1855 Hector Gavin died in the accidental discharge of a revolver, caused by his brother William Gavin of the 17th Lancers, a veterinary surgeon, who shared his tent. The gun (Hector's service revolver) apparently went off as he handed it to his brother, grip-first, and his brother grabbed it touching the trigger, and firing into Hector's body.
In December 1837 he married Margaret Greenfield, daughter of James Greenfield.
- Hunt, Tristram. "Gavin, Hector (1815–1855)". Oxford Dictionary of National Biography.
- Spriggs, Edmund Anthony (July 1984). "Hector Gavin, MD, FRCSE (1815–1855) – his life, his work for the Sanitary Movement, and his accidental death in the Crimea". Medical History. 28 (3): 283–292. doi:10.1017/s0025727300035948. PMC 1139447. PMID 6390025.
- Edinburgh Post Office Directory 1815
- Gavin tomb, New Calton Cemetery
- Edinburgh Post Office Directory 1830
- Gavin tomb, Old Calton Cemetery
- "Obituary. Dr. Hector Gavin". The Lancet. v. 1: 502. 12 May 1855. doi:10.1016/s0140-6736(02)62215-9.
- "Obit. Dr. Hector Gavin". The Spectator. 12 May 1855. p. 15.
- W.Justyne. 1865. A guide to Highgate Cemetery. London