It was at this time he contracted a very intimate friendship with George Stepney. In 1682, when Stepney was elected at Cambridge, Montagu asked to be moved to Cambridge in order to join his friend, without waiting for the advantages of another year. His relation, Dr. John Montagu, was then Master of Trinity College, and took him under his wing. At Cambridge he began a lasting association with Isaac Newton.
In 1685, Montagu's verses on the death of King Charles II made such an impression on the Earl of Dorset that he was invited to town and introduced to other entertainments. In 1687, Montagu joined with Matthew Prior in "The City Mouse and the Country Mouse," a burlesque of John Dryden's The Hind and the Panther. He sat in the Convention Parliament of 1689. At about the same time he married the Countess Dowager of Manchester, and intended taking Holy Orders, but changed his mind and purchased for £1,500 a position as Clerk of the Council.
After the House of Commons he rose quickly, becoming one of the Commissioners of the Treasury and a member of the Privy Council. In 1694 he became Chancellor of the Exchequer and in 1695 was involved in the successful recoinage project. In 1698, having been appointed to the first Commission of the Treasury, he was also one of the regency in the King's absence. The next year he was made Auditor of the Exchequer, and the year after created Baron Halifax, of Halifax in the County of Yorkshire, with remainder to his nephew George Montagu. His impeachment by the Commons failed, when the Articles were dismissed by the House of Lords.
On the accession of Queen Anne, Montagu was dismissed from the Council, and in the first Parliament of her reign was again attacked by the Commons, and again escaped by the protection of the Lords. In 1704 he wrote an answer to Bromley's speech against occasional conformity. He headed the inquiry into the danger of the Church. In 1706 he proposed and negotiated the Union with Scotland and when the Elector of Hanover received the Garter, after the Act had passed for securing the Protestant Succession, he was appointed to carry the ensigns of the Order to the Electoral Court. He sat as one of the judges of Henry Sacheverell, but voted for a mild sentence. Being now no longer in favour, he obtained a writ for summoning the Electoral Prince to Parliament as Duke of Cambridge.