A paedophile tried to take his own life after he was arrested for sexually abusing two young girls over a four-month period.
Alan Hine, 54, from Abbey Field View, Colchester, in Essex, nearly succeeded in the suicide bid, but was saved.
Last month he pleaded guilty at Colchester Magistrates' Court to intentionally inciting the two young girls to touch him in a sexual manner.
The girls were aged just four and six and the abuse happened between January 1 and April 30 this year in Colchester.
Hine is due to be sentenced at Ipswich Crown Court.
He was remanded in custody ahead of sentence for his own safety.
A record of the hearing said custody was required "on the grounds that (there is a) substantial ground for believing that he would fail to answer bail and for his own protection.
"This is due to the nature and seriousness of the offences and likely sentence.
"He has tried to take his own life and very nearly succeeded."
Hine will also be required to sign the sex offenders register for a period to be set by the crown court.