He entered parliament in 1961 and served under Edward Heath as Secretary of State for Northern Ireland (1973-1974), and Margaret Thatcher as Defence Secretary (1979-1981), Leader of the House of Commons and Lord President of the Council (1981-1982) then Foreign Secretary (1982-1983). He stood down at the 1987 election and was made Lord Pym of Sandy.