Parliamentary democracies tend to have no fixed term limits; the ruling party can maintain control over the administration, and appoint the prime minister, as long as there is confidence in his/her service. The British Prime Minister with the longest single term was Sir Robert Walpole, lasting 20 years and 314 days from 4 April 1721 until 11 February 1742. This is also longer than the accumulated terms of any other Prime Minister.The shortest ever period was only two days, a record held by the Earl of Bath, from 10 February to 12 February 1746, who was asked to form a government but was unable to find more than one person who would agree to serve in his cabinet. For Canada, William Lyon Mackenzie King was Canada's longest serving prime minister at 21 years, 154 days, non-consecutively.
There is no fixed term length for a Canadian Prime Minister. He can be incumbent until he resigns, is dismissed, or dies.
Parliament has a turn-over time of five years maximum, at which point an election is held. If something happens before an election, the Governor General (the Queen's representative in Canada) may dissolve parliament and hold an election sooner.