A 36-year-old teacher at an Islamic boarding school in the city of Bandung was sentenced to death after the court overturned a previous ruling according to which he would have served a life term in prison.
Herry Wirawan's case had drawn widespread criticism of abuse in the country's schools.
"We accept the appeal of the prosecutors [and] hereby punish the defendant to a death sentence," read a statement by the trial judge.