CAIRO - An up-and-coming challenger to Egyptian President Abdel Fattah al-Sisi may be barred from running against him after receiving a jail sentence on Monday for public indecency.

A Cairo court sentenced human rights lawyer and former presidential candidate Khaled Ali to three months in prison for making what was deemed an obscene hand gesture on the steps of a courthouse after winning a case against the government.

Ali's political profile has soared since he won the case in January nullifying an unpopular government transfer of two Red Sea islands to Saudi Arabia.

He has not formally announced if he will oppose Sisi in the elections, but has indicated he intends to. 

Ali denies making the gesture and describes the case as punishment for his work trying to nullify the Red Sea islands deal and his intention to challenge Sisi.

Monday's verdict can be appealed without Ali serving jail time during the appeal process. But a final verdict delivered against Ali, which could come immediately if his appeal is rejected, would prevent him from running in elections, his lawyer told Reuters.

Sisi came to power in 2014, a year after he led the military in ousting elected but unpopular Islamist President Mohamed Mursi. He is expected to run again in 2018 and to win in the absence of any major challengers.

Ali, a socialist, ran for president in 2012 and came seventh and now leads the leftwing Bread and Freedom Party, several members of which were arrested earlier this year on charges that include inciting against the state.

(Reporting by Ahmed Mohamed Hassan and Ahmed Aboulenein; Writing by Eric Knecht Editing by Jeremy Gaunt) ((eric.knecht@thomsonreuters.com; +20 2 2394 8102; Reuters Messaging: eric.knecht.thomsonreuters.com@reuters.net))