JERUSALEM — The Israeli Supreme Court reduced a prison sentence for Ehud Olmert, a former Israeli prime minister, on Tuesday to 18 months from six years after overturning the main part of his conviction on bribery charges.

Mr. Olmert, the first Israeli prime minister ever sentenced to prison, appears to have run out of legal options and is scheduled to begin serving his term on Feb. 15, seven years after he was forced out of office because of the allegations of corruption.

He was convicted in March 2014 of taking bribes, in part to facilitate the construction of a huge housing complex known as Holyland while he was mayor of Jerusalem.

“A large stone has been lifted from my heart now that the Supreme Court has acquitted me of the main charge, which is Holyland,” Mr. Olmert said in televised remarks outside the courtroom immediately after the ruling, describing the case as “a black cloud” that had long been hanging over him and his family.