 He afterwards served as Canon of St Paul's Cathedral.Melvill was the fifth son of Philip Melvill (1762–1811), an officer in the army, who was lieutenant-governor of Pendennis Castle from 1797 till 1811, by his wife Elizabeth Carey (1770–1844), daughter of Peter Dobrée of Beauregard, Guernsey.He was born at the castle in 1798.