A top Egyptian court issued a final ruling on Monday rejecting a government plan to transfer two uninhabited Red Sea islands to Saudi Arabia in a deal that had provoked outrage among Egyptians and prompted rare protests.
Monday's ruling rejected the government's appeal against a lower court's decision to annul the handover agreement, signed in April.
The Supreme Administrative Court said the two islands, Sanafir and Tiran, are Egyptian, debunking the government's claim that they were Saudi.
Cheers broke out in the Cairo courtroom as the judge read out the verdict which said the government had failed to provide evidence for the transfer of the islands.
The islands at the mouth of the Gulf of Aqaba control the narrow shipping lanes running north to the Red Sea port cities of Eilat and Aqaba, in Israel and Jordan.
The fate of the two islands has been at the heart of friction between Riyadh and Cairo over a string of regional issues, including Syria and Yemen.