Williams was born in Newark-on-Trent; his father Charles Williams was also a Congregational minister and a prolific author. He studied at University College and New College in London. His first post in 1857 was at the Congregational church at Claughton, Birkenhead. From 1861, he lived and worked as a tutor at the Congregational Institute in Nottingham, alongside its director John Brown Paton.
Williams enjoyed a deserved reputation as a pioneer railway historian. "Our Iron Roads" appeared in 1852 and had run to seven editions by 1888, selling over 10,000 copies. The book gives a detailed account of the early history of the railways in Britain and explains at length the construction of embankments, cuttings, tunnels and viaducts. He also wrote "The Midland Railway, its Rise and Progress" (1876), which covers the history of the Midland Railway and also describes the countryside and historic sites that were made more accessible by its construction.
He also wrote a book on astronomy, "The Wonders of the Heavens" (1862), and "Nottingham Past and Present" (1878), in addition to several religious pamphlets.