He was born in
Barnton House west of Edinburgh, on 29 May 1809, the eldest son of George Ramsay and his wife Jean Hamilton, daughter of John Hamilton
Baron Belhaven. Barnton House (previously known as Cramond Regis) was commissioned by his father in 1784 to replace an earlier house, and was designed by
Robert Adam. It was extended by
architect David Hamilton in 1810. He was privately tutored then studied at
Christ Church, Oxford graduating in 1828, and later that year married Mary Sandilands, daughter of
James Sandilands, 10th Lord Torpichen—with whom he had 1 son, Charles William Ramsay (1844–1865). He inherited the estates of his father when "still an infant", an event which saw him conferred the distinction of "the richest commoner in Scotland". Barnton House was demolished around 1960 but the Gothic style gatepiers of 1810 still exist on Whitehouse Road. ==References==