South Africa's highest court Thursday cleared the way for all registered voters who are overseas to cast ballots in national elections next month.

In a landmark ruling, the Constitutional Court decided that all registered voters living overseas can vote in the elections on April 22, if they notify the elections commission first, the SAPA news agency reported.

A legal change in 2003 had imposed sharp limits on which overseas voters could cast ballots. The law was challenged in court by a South African teacher working in Britain, who said the limits disenfranchised voters living abroad.

The court said that ballots could be cast from overseas for national elections, but not in provincial polls. And the court said voters cannot register overseas.

The court ruled that South Africans abroad must tell the chief electoral officer where they intend to vote before March 27, SAPA said.

The Independent Electoral Commission (IEC) said it was ready to comply with the ruling.

"All we have to look at now is the numbers we are talking about," chief electoral officer Pansy Tlakula said.

"We are relieved this is over. There is certainty on the matter and we will be able to start preparing for overseas votes," she said.

She said about 5,000 people had already notified the commission of their intention to vote, but said she expected that number to at least double.

More than 23 million South Africans are registered to vote for next month's polls.

Some political parties have expressed their support for the court saying that it would ensure that all South Africans, including those temporarily living abroad, could exercise their voting rights.