He was originally set to hang for murdering a taxi driver.
But Chinese national Wang Wenfeng was shedding tears of relief on Wednesday when he was given life in prison and 24 strokes of the cane instead.
The 35-year-old, who is married with a 10-year-old daughter, is the fifth murderer on death row to be re-sentenced after judges were given the discretion this year to impose either the death penalty or life imprisonment in certain categories of murder.
All five cases resulted in the death sentences - mandatory previously - being commuted to a life term and caning.
On Wednesday, Chief Prosecutor Bala Reddy pressed for Wang to be sentenced to death, arguing that he had committed a pre-meditated murder in cold blood.
Citing statistics of crimes against taxi and bus drivers, he argued that there was a need to deter violent crimes against public transport workers.
Wang's lawyer, Mr Wendell Wong, argued that this was a case of a botched robbery and that the death penalty should be reserved for the most heinous cases.
Justice Lee Seiu Kin concluded that "the ends of justice" are served by a life term and 24 strokes - the maximum he can impose, short of hanging.
The judge said it was one thing to impose a higher fine or longer jail term as a deterrent but quite another to say that a death sentence was necessary and appropriate when life imprisonment was an option.