At the 1st parliamentary election held in 1947 Ebrahim, as an Independent, in the seat of Pottuvil. He received 7,407 votes (55.9% of the total vote) defeating the only other candidate, A. R. A. Razik (representing the United National Party), by 1,899 votes.[2][3] Razik was a prominent Muslim leader and a founding member of the UNP, who had been denied the party's nomination for Colombo Central and was forced to contest Pottuvil, an area which he did not have a personal political base.[4][5] In 1947 Razik was granted a seat in the Senate of Ceylon and was subsequently elected to parliament in the next parliamentary election. Ebrahim was one of only six Muslims elected to the first parliament of Ceylon.[6] Later in his first term of office he joined the UNP.