On the merger of Queen's and Sydenham colleges in 1868 he was appointed Professor of Medicine, a position he held until 1892. He became a doctor at Birmingham General Hospital, where he was galvanized by what he described as a "new atmosphere of modern thought and scientific enterprise" compared to the traditionalism of medicine in Dublin. He was established as a researcher by a series of articles starting in 1863 covering treatment for peptic ulcers, valvular heart disease and cyanosis. He was the first author in England to publish a text covering premature death among diabetics from ketoacidosis. His most famous research was his efforts to use diethyl ether in the treatment of phthisis. In 1870 he published Method and Medicine, a defence of scientific research in medicine. This was his last major piece of medical work; in the 1870s he became involved the public health and the social applications of medicine. In 1873 he was elected a Fellow of the Royal College of Physicians.
Parliamentary career
In 1885 he was elected as a Member of Parliament for Chester as a Liberal candidate with a programme of free education and improved housing for the poor. Although a strong supporter of Joseph Chamberlain, Foster did not reject Irish home rule in 1886 as Chamberlain did. In 1886, he was made President of the National Liberal Federation, where he played a large part in keeping Chamberlain's supporters loyal to William Ewart Gladstone. Foster was unseated by the faggot votes of the duke of Westminster's tenants at the Liberal defeat in the 1886 election, and a knighthood the same year suggested a retirement from politics, but Foster returned to Westminster in 1887, elected for Ilkeston after a by-election. In 1892 he was made Parliamentary Secretary to the Local Government Board, becoming the first doctor to hold a ministerial post in Britain. He organised the sanitation campaign between 1892 and 1895, which successfully prevented the 1893 Cholera epidemic reaching Britain. When the Liberals returned to power in 1905 some had predicted a cabinet position for him, but he was passed over on grounds of his age. In 1906 he was made a member of the Privy Council. After his sixth victory at Ilkeston in 1910 he was asked to vacate his seat to allow J. E. B. Seely, recently defeated in his own constituency, to take his place. Foster took the position of Steward and Bailiff of the Manor of Northstead, effectively resigning from the House of Commons, and Seely was duly elected in March 1910. In 1910 he was elevated to the peerage, as Baron Ilkeston of Ilkeston in the County of Derby, although he did little in the House of Lords due to his growing ill-health. A bowel obstruction was successfully operated on in 1911, but he died of bowel cancer in London on 31 January 1913, aged 72.