johnston was born about 1648, the only son of sir george johnston, 2nd baronet by his wife, a daughter of sir william leslie, 3rd baronet of wardes. in 1660 his father had sold the family estate of caskieben in aberdeenshire to sir john keith, who renamed it keith hall. johnston was a captain in the army, and served under king william iii in flanders and in ireland, where he was present at the battle of the boyne.