Cranston was commissioned lieutenant on 21 March 1755 and promoted commander of the sloop Swallow 10 on 27 August 1760, in which vessel he captured the privateer Vautour on 9 January 1761, and the letter-of-marque Tigre on 12 February. For a short period Commander Robert Brice briefly acted for him in command of the Swallow.
He was posted captain on 7 April 1762, and after commissioning the new Blenheim 90 he took her out to the Mediterranean and handed her over to Captain Broderick Hartwell in May. He then removed to the Squirrel 20 in which he was employed on the same station, and which he commanded for the remainder of the Seven Years War through to 1763.
After a period ‘on the beach’ he was appointed to the Plymouth-based guardship Ocean 90 in October 1770 for the duration of the Falkland Islands dispute, and in the following summer transferred to the Intrepid 64, initially serving as a guardship at Plymouth but then departing for the East Indies in April 1772. After returning home the ship was paid off at Plymouth in April 1775.
In June 1778 Cranston recommissioned the Defence 74 for the Channel fleet, and although he was not present at the Battle of Ushant on 27 July he did sit on the court martial of both Admiral Hon. Augustus Keppel and Vice-Admiral Sir Hugh Palliser. Unfortunately the Defence was too heavily laden with ballast and when she did get to sea she promptly sprung her bowsprit through excessive pitching and rolling and was obliged to retire to Spithead for repairs. Having been coppered at Portsmouth in the spring of 1779 she continued in the Channel fleet, with Captain John Symons acting for Cranston during part of the year.
At the end of 1779 Cranston joined Admiral Sir George Rodney’s Leeward Islands-bound fleet and took part in the Moonlight Battle off Cape St. Vincent on 16 January 1780, the Defence being much engaged and suffering casualties of ten men killed and twenty-one wounded. After a refit at Gibraltar she was sent to Minorca with a merchant convoy in company with the Marlborough 74 and Invincible 74, after which she rejoined the Channel fleet. In July 1780 the Defence played a prominent part when the fleet intercepted a homeward-bound French West Indian convoy, taking one merchantman and leading the pursuit, albeit fruitlessly, of the escort vessel, Fier 50. Cranston was thereafter present in the Channel fleet campaign of June-December, the relief of Gibraltar on 12 April 1781, and the Channel fleet campaign from June to November 1781.
He left the Defence in January 1782 after she had been ordered out to the East Indies and assumed command of the Bombay Castle 74, which ship had been gifted by the East India Company to the nation. However, this vessel was not ready for service when Admiral Lord Howe sailed with the fleet for Gibraltar in the autumn, and thus Cranston left the command at the end of the year without seeing any further service.
Cranston died at his residence in Lewes on 31 July 1790, seven weeks before he would have been advanced to flag rank.
During his career he was presented with the gift of a small-sword by Admiral Lord Rodney.