Allen was admitted to the Virginia bar in 1818, and opened his first office at Campbell Courthouse, Virginia in 1819. He soon moved to Clarksburg, the seat of Harrison County where he practiced law in the surrounding counties for seventeen years, after 1830 in partnership with Gideon D. Camden, who also later became a circuit judge. In 1828, voters from the trans-Appalachian counties of Kanawha, Logan, Mason, Cabell, Randolph, Harris, Lewis and Wood elected Allen to represent them in the Virginia Senate. However, he did not serve a full four year term, because the Virginia Constitutional Convention of 1829-1830 led to a reorganization of districts. His growing district was split, and William McComas came to represent Kanawha, Mason, Cabell, Logan and Nicholas Counties, and John McWhorter representing Harrison, Lewis and Wood Counties. In 1832, Allen successfully ran for election to the U.S. Congress, and was a member of the 23rd United States Congress, serving for a year from March 4, 1833 to March 4, 1835. In the 1834 election, voters in Harrison, Lewis and Preston counties elected Allen as their Commonwealth’s Attorney. He served for about a year before Virginia's General Assembly elected him as Judge for the seventeenth Circuit in 1836. Allen then moved to Botetourt County where he held his first court. In December 1840, the Virginia General Assembly elected Judge Allen to the Supreme Court of Appeals. In 1851 his fellow judges elected him as the court's President during another reorganization.
After Abraham Lincoln's election in November 1860, Judge Allen called a mass meeting in Botetourt County on December 10, 1860. He presented a resolution that he had drafted extolling Virginia's contributions to the nation's founding and condemning the north for "pharisaical fanaticism" concerning slavery and urged calling a convention to consider secession. The meeting overwhelmingly approved his document, which came to be called the "Botetourt Resolutions." Allen's sons volunteered for Confederate army service. While the three eldest Allen boys and their brother in lawWilliam Watts survived the conflict, the year 1862 proved disastrous for the family. Capt. John J. Allen St. lost an arm as a result of a wound sustained at the Battle of Malvern Hill, Master sergeant George Jackson Allen died in the Seven Days' Battle and Private Baldwin Allen died of typhoid fever after his artillery unit was assigned to Tennessee.
Death and legacy
Allen resigned from the Court in April 1865 and retired to private life at his home,Beaverdam, near Fincastle, the Botetourt County seat. He was buried at Lauderdale cemetery in Botetourt County after dying in 1871. Nearly three years later, his eldest son, James J. Allen Jr., won election as Botetourt County's delegate. Though he served but a single term, his middle brother Henry Clay Allen began the first of his four terms representing the family's ancestral Shenandoah County in 1875. John James Allen would then follow his father's path and become a circuit judge in Botetourt County for the rest of his career, and H.C. Allen would become the body's speaker in 1877-1879 before becoming a judge in Shenandoah county.