 Maclagan, the fifth son of a distinguished Scottish physician David Maclagan FRSE (1785–1865) was born in Edinburgh in 1826, and educated at the Royal High School.His elder brother was the surgeon and scholar Douglas Maclagan.He served five years in the Indian Army rising to the rank of lieutenant and resigning on grounds of ill health.