Lawrence was born on June 26, 1819 in Mount Pleasant, Ohio. He attended Tidball's Academy in Knoxville, Tennessee. After teaching at Pennsville and McConnelsville, Ohio, he was graduated in 1838 from Franklin College in New Athens, Ohio. He was then graduated in 1840 from law school at the University of Cincinnati, and was admitted to the bar. In 1873, Lawrence was awarded the LL. D. from Franklin College.
In 1841, Lawrence moved to Bellefontaine, Ohio, and there set up his law practice. From July 15, 1841 to July 15, 1843 he was law partner of Benjamin Stanton, and from July, 1851 to February, 1854 with his law student William H. West. From 1841 to 1843, he continued his studies, then in the field of medicine. In 1842, he became the Commissioner of Bankruptcy for Logan County.
From 1845 to 1847, Lawrence served as the editor of the Logan Gazette, which later became the Bellefontaine Examiner. During this time, Lawrence was elected as the Logan County Prosecutor (in 1845). He also served as a member of the Ohio House of Representatives, in 1846 and 1847. In 1849, Lawrence was first elected to the Ohio Senate, serving until 1851 when he became the reporter of the Ohio Supreme Court. He returned to the Ohio Senate in 1854. He also served as an editor of Western Law Monthly from 1859 to 1862. In 1860 or 1861, Lawrence built a house along North Main Street in Bellefontaine; today, the William Lawrence House remains largely intact and is listed on the National Register of Historic Places.
In 1857, Lawrence was appointed Judge of the Court of Common Pleas and of the District Court, serving until he resigned in 1864. In 1862, he entered the Union Army as colonel of the 84th Ohio Infantry, a three-month regiment. In 1863, Lawrence was appointed to serve as the wartime judge for the United States district court in Florida; however, he declined the appointment.
On March 4, 1865, William Lawrence was inaugurated as the U.S. Representative for the 4th district of Ohio, having been elected to this office the previous November. He supported the adoption of the Fifteenth Amendment, stating in an 1866 speech that it would "protect every citizen, including the millions of people of foreign birth who will flock to our shores to become citizens and to find here a land of liberty and law."