Togo's parliament has voted to reinstate the two-term limit for presidents, but the change does not apply to the current leader.
President Faure Gnassingbé will be eligible to run in future elections in 2020 and 2025, meaning he could potentially remain in power until 2030.
Opposition politicians wanted the new cap to apply to President Gnassingbé but the ruling party proposal won out.
The announcement was made shortly before midnight after 90 out 91 MPs cast a secret ballot in favour of the constitutional revisions.
The matter has stirred controversy in recent years.
Yet the changes are not so surprising given that two-thirds of the representatives are allied to the governing party, following last year's legislative election which the opposition boycotted.
During a debate in parliament, several MPs threatened to boycott the vote over a proposal to also extend the presidential mandate to seven years.
In the end, lawmakers voted to stick with five years.
The Gnassingbé family is the longest-running political dynasty in Africa - Faure Gnassingbé succeeded his father in 2005 after his more than 50 years of autocratic rule.
Have your say
More World Headlines
- South Africa's anti-corruption chief lied under oath
- CIA spies sentenced to death' in Iran
- President 'bans national anthem being sung in his absence'
- Kenya's finance minister, top officials arrested for corruption
- Nigerian serviceman returns lost parcel full of cash
- England's seaside towns where young people might disappear
- Turkish nationals kidnapped in Nigeria's Kwara State
- The teenager whose murder was exploited for clicks
- British Airways suspends flights to Cairo
- Dangerous heatwave starts hitting US and Canada
- I sat my exams 30 minutes after giving birth
- Police name suspect in Japan animation studio fire
- Eritrea Orthodox Church ex-leader expelled for 'heresy'
- Ramaphosa 'deliberately' misled parliament - Public Protector
- US shoots down Iranian drone