He was the eldest son of Admiral of the Fleet Sir Thomas Byam Martin, comptroller of the navy (1815 - 1831), and grandson, on the mother's side, of Captain Robert Fanshawe, who commanded the "Namur 90" in George Rodney's victory of 12 April 1782. He had two brothers, including Henry Byam Martin (born June 1803).
Entering the navy at the age of twelve, his fathers interest secured his rapid promotion: he was made a lieutenant on 15 December 1820; on 8 February 1823 he was promoted to be commander of the Fly sloop, his good service in which in support of the interests of British merchants at Callao secured his promotion as captain on 5 June 1824. He served in the Mediterranean during the periods of 15 November 1826 - 1831 (Captain, Samarang) 19 July 1844 - 31 January 1845 (Captain, Queen), 30 January 1845 - 18 October 1845 (Captain, Trafalgar), and 7 December 1847 - 21 December 1849 (Captain, Prince Regent).
In 1849-1852, he was commodore commanding the Channel squadron, and gave evidence of a remarkable aptitude for command. He was made rear-admiral in May 1853, and for the next four years was superintendent of Portsmouth dockyard. He was made vice-admiral in February 1858, and after a year as First Sea Lord, he was appointed commander-in-chief of the Mediterranean Fleet in 1860, with his flag in HMS Marlborough (captain - William Houston Stewart).
The discipline of the navy was then bad. It was a tradition sprung from the wholesale shipment of gaol-birds during the old war, that the men were to be treated without consideration; moreover the ships had been largely filled up with bounty men bought into the service with a £10 note, without training. Out of this unpromising material Martin formed the fleet which was at that time the ideal of excellence.
He had no war service, and, beyond the Italian disturbance of 1860-61, no opportunity for showing diplomatic ability. But his memory lives as that of the reformer of discipline and the originator of a comprehensive system of steam manoeuvres. He became an Admiral in November 1863. On 4 December, he succeeded to the baronetcy, which had been conferred on his grandfather, but passed to Martin upon the death of his cousin, Sir Henry, the 3rd Baronet.
His last appointment was the command at Plymouth, 1866-1869, and in 1870 he was put on the retired list. In 1873 the GCB was conferred on him. He died at Upton Grey, near Winchfield, on 24 March 1895. He was twice married: 24 July 1826, Hon. Anne Best (died 1836), daughter of Lord Wynford; and again 21 May 1838, Sophia, daughter of Richard Hurt. Martin left, besides daughters, one son, Sir Richard Byam Martin, who succeeded as 5th Baronet.