In 1918 Wilfley was appointed to the United States Senate by Governor Frederick D. Gardner as a Democrat to fill out the term of William J. Stone, who had died in office on April 14, 1918. Wilfley served from April 30 to November 5 and was the chairman of the Committee on Industrial Expositions. He unsuccessfully sought the Democratic nomination for the Senate seat but lost it to Joseph Folk, who in turn lost the general election to Republican Selden P. Spencer.
Later life and death
After leaving the Senate, Wilfley returned to St. Louis and resumed his legal practice, becoming president of the Missouri Bar Association in 1925. He died in St. Louis in 1931 at the age of 60 and is buried in Oak Grove Cemetery.