Uganda's Constitutional Court delivered its ruling on the consolidated presidential age limit petition at the High Court in Mbale on Thursday.
The court was to rule on a number of issues among them the lifting of the age caps, extension of the term of Parliament and the raid on the House last year.
In the verdict, the five-judge bench, by a majority of 4-1, upheld the removal of the 75-year age limit that allows President Yoweri Museveni, now 73 and in office for 32 years, to seek a sixth term.
The judges also ruled against the reinstatement of the presidential two-term limits which were scrapped in 2005 to allow Mr Museveni seek re-election.
The court unanimously rejected the extension of the tenure of Parliament and Local Councils by two years, stating it was unconstitutional to amend the law without subjecting it to a referendum.
The judges termed the move by the lawmakers as "selfish" and subjective to "narrow personal interests above the public good".
This means that elections will continue to be held every five years and are due in 2021.
Petitioners had also sought the court to declare as illegal the suspension of Members of Parliament by Speaker Rebecca Kadaga after a dramatic scuffle during debate on the age limit Bill last year. The court declined stating that the Speaker had to take action given the circumstances in the House.
On the raid by security operatives who evicted mainly opposition MPs from Parliament on the September 27 incident, the judges said the conduct of lawmakers necessitated some intervention but condemned the handling of the incident.
The five judges were deputy Chief Justice Alfred Owiny Dollo, judges Kenneth Kakuru, Remmy Kasule, Cheborion Barishaki and Elizabeth Musoke.