The man, named only has Roni, was due to be hit 169 times but collapsed after 52. Medical examiners ruled that he was unfit to continue.
Officials in the ultra-conservative e Indonesian city of Banda Aceh have pledged that he will be given the rest of the punishment after recovering.
Roni had already served six months in jail before the beating was carried out, which had reduced his sentence from 175 to 169 – one for each month behind bars.