Gapes was born in Saffron Walden in Essex, England in 1822. He went to school there and continued his training in London. He held employment with the same firm in London for 22 years. He married Jane Le Lean in 1843 (b. 1823 or 1824), and they had four daughters and six sons.
Gapes and his wife Jane came out with their children and other relatives - Hannah (21 years), Charlotte (16 years), Thomas (11 years), Mary (7 years), Angelina (5 years) and Emily (8 months), plus his cousin Lizzie Westwood (b. 1826 in Hertfordshire) emigrated to the colony, leaving Gravesend on 29 August 1859 and arriving in Lyttelton on 4 December 1859 on board the Regina.
Gapes started a glass, paint and paperhanging business in 71 Victoria Street. In 1889, he passed the company to his son Thomas.
He was a member of many organisations and bodies, often in a leading role, including the Christchurch Hospital Board, Canterbury Lodge Freemason, the Order of Foresters, and Court Star of Canterbury.
As a flautist, he gave many concerts with Sir John Cracroft Wilson.
Before 1916, elections for Christchurch City Council were held annually. Gapes was elected onto the city council six times: first in February 1873 in a by-election, then in 1874, 1877, 1878, 1879 and 1881.
The mayor was for the first time elected by voters on 20 December 1876; until the previous year, the mayor was chosen from amongst the city councillors, and they usually elected the most senior councillor.
The 20 December 1876 mayoral election was contested by Gapes and Charles Thomas Ick, with Gapes representing working class interests, whereas Ick represented the wealthier part of the population. Gapes and Ick received 680 and 515 votes, respectively, and Gapes was thus declared elected. Gapes was sworn in as mayor at the next Christchurch City Council meeting on 2 January 1877.
At the end of 1877, Gapes was challenged by Henry Thomson for the mayoralty. Gapes declared that he would not have wanted to oppose a city councillor standing for the office of mayor, but that he stood to clear up his reputation, as unwarranted accusations had been made against him. Thomson, over the course of the election campaign, started to believe that he would not have a chance at the election. The result was very close, with Thomson receiving 474 votes against 461 votes for Gapes. The returning officer declared Thomson elected at the evening of the election day (28 November 1877). Thomson was installed as mayor at a meeting on 19 December 1877.
Gapes was elected again on 24 November 1880, when he defeated Aaron Ayers. He was installed as mayor on 15 December 1880.
Gapes announced on 25 November 1881 his candidacy for a third term as mayor, as he was not satisfied with the other two contenders for the position, the timber merchant Charles Benjamin Taylor, and George Ruddenklau. However, on 28 November, Gapes advertised that he had withdrawn from the contest. The election was won by Ruddenklau on 30 November, possibly helped by the support of The Star just prior to the election. Ruddenklau was installed as the next mayor on 21 December 1881.
His son Thomas Gapes was the 20th Mayor of Christchurch.
The Gapes family was of humble origin, and they are an example of the opportunities that were available to immigrants to New Zealand. When the Canterbury edition of the Cyclopedia of New Zealand was produced, it was his son Thomas who wrote the various entries for the Gapes family. As the Cyclopedia was vanity press, it gave him the chance to downplay the family's humble background, and he focussed on their important associations in Christchurch. Thomas Gapes stated about his father that "while in London Mr. Gapes was intimately associated with the early pioneers of Canterbury, and took a very active part in the business of colonisation, especially in connection with the Canterbury settlement." This was rather unlikely, though, as the Gapes family travelled to New Zealand as assisted immigrants, i.e. they had their journey subsidised for them; assisted immigrants were not those who were influential in their homeland.
James Gapes' youngest son, Alfred, died aged 18 on 6 June 1886. He was buried at Linwood Cemetery.
His son James became an alcoholic and eventually died penniless on 16 October 1894. On 5 August 1876, James Gapes (junior) was fined 20s for "drunkenness, assaulting and resisting the police". As the case had been reported in the newspaper and due to father and son sharing their first name, Gapes (senior) took out an advertisement later that month to protect his reputation. Alice Gapes (née Swindell, married 1875), the wife of James Gapes (junior), outlived him by eight years. The Christchurch City Library holds an interesting biography on her, not because she had a public persona, but as an example of a woman coping as best as she could during the Victorian time.
Gapes' third daughter, Angelina, married L. H. Nelson on 10 August 1876.
His fourth daughter, Emily, married Frank John Preston on 12 June 1879.
Gapes' wife, who was well regarded in Christchurch for her attitude to charity, died on 5 July 1886, aged 62 years. Gapes outlived her for 13 years and died in Christchurch on 22 October 1899, aged 77 years. He is buried at Linwood cemetery.
His sister Charlotte died aged 89 on 27 September 1928.