Nicaraguan President Daniel Ortega appears to have won the right to seek re-election in 2011, though opponents call the decision illegal and are vowing to fight it.
The constitutional commission of the Supreme Court overturned a ban on consecutive re-election and on serving more than two terms, and the head of Nicaragua's electoral commission said the ruling is final.
Only members of Mr Ortega's Sandinista party took part in the ruling by the heavily politicised court.
But the president of the Supreme Court, a member of the opposition Liberal Party, refused to recognise the decision.
"Ortega is completely disqualified from being a candidate" in the next elections, Justice Manuel Martinez said.
Opposition leaders said the commission ruling was an underhanded power grab by Mr Ortega, who was first named president after the Sandinista rebels toppled dictator Anastasio Somoza in 1979.
Liberal Party judges were not present at Monday's vote and say it must be approved by the full Supreme Court. But they lack the votes to overturn it because the death of a Liberal Party justice tipped the balance of the court to the Sandinistas.
Under a power-sharing deal, the Sandinistas and Liberals each appoint eight members of the court and split influence over other agencies as well, freezing out third parties.
Mr Ortega called the court's decision "indisputable" and asked his opponents to have faith in the electorate.
"The people will decide at the election. Why deny them the right to choose whomever they want for whatever post?" Mr Ortega said at a rally broadcast live on radio and television.
Latin American leaders such as Venezuela's Hugo Chavez, Ecuador's Rafael Correa and Colombia's Alvaro Uribe also have manoeuvred to extend their terms in office.
In Central America, leaders of the interim government of Honduras have accused ousted President Manuel Zelaya of attempting to undo presidential term limits through a referendum on whether to revise the constitution. Mr Zelaya vehemently denies the accusations.
Mr Ortega left office in 1990 after opposition candidate Violeta Chamorro defeated him in nationwide elections. He was re-elected in 2006.