John F.E. Barnes, son of a civil engineer, was educated at Trinity College, Dublin and was apprenticed for five years to his father, who was then town surveyor of Blackrock, county Dublin. After completing his apprenticeship he worked as a civil engineer in Ireland, particularly on flood protection works, sewerage schemes and waterworks in the north of the country. He became an associate of the Institution of Civil Engineers of Ireland 1876 and a member three years later. After his marriage to Mary S. Graves in 1879 he came to Natal that same year and in January 1880 started work as a government land surveyor. Two years later he was appointed borough engineer of Durban. In this capacity he helped to improve the town's water supply from various local rivers. In January 1888 he entered the Natal civil service as assistant colonial engineer and assistant surveyor-general, occopying the latter post only to July 1890, when the two posts were separated. During these years he several times acted as colonial engineer, with a seat in the Executive and Legislative Councils. After the introduction of responsible government he was appointed chief engineer and head of the Public Works Department in January 1894. From 1888 he was responsible for various engineering works, bridges and buildings throughout the colony, including the architectural design of the Natal Legislative Council building.
During the Anglo-Boer War Barnes raised and directed a European Labour Corps, a Native Labour Corps, and an Indian Ambulance Corps. For this and his engineering services to the military he was appointed a Companion of St Michael and St George (CMG) in August 1901. In 1904 he visited the St Louis World's Fair as commissioner for Natal and published an account of his visit in pamphlet form in Pietermaritzburg. A paper by him, "Alcohol for industrial purposes", dealing with its production and use in Natal, was published in the Natal Agricultural Journal (Vol. 13, pp. 26-31) in 1909.
Barnes retired from the civil service after the formation of the Union of South Africa at the end of 1910 and thereafter practised privately as a consulting engineer to at least 1919, also serving on various government boards. An interesting contribution by him as consulting engineer to the Borough of Ladysmith is his "Report on the proposed flood prevention and drainage of Ladysmith" (Pietermaritzburg, 1918), dealing with a problem that would continue to plague the town throughout the twentieth century.
Barnes was a member of the (British) Institution of Civil Engineers from 1889, and a fellow of the Royal Colonial Institute. In 1902 he became a founding member of the South African Association for the Advancement of Science, and was still a member by 1910.