He attended the Glasgow Academy and then continued his education at the University of Glasgow with Thomas Anderson and then went to study in Germany at the University of Tübingen with Wilhelm Rudolph Fittig where his doctoral thesis was entitled Investigations in the Toluic and Nitrotoluic Acids.