AN Indonesian teenager chopped off his penis and tossed it down a well after learning his girlfriend intended to marry another man.

The 19-year-old from a village in Central Java was lucky to survive the self surgery, health authorities said.

"He arrived at the hospital last Thursday in critical condition from blood loss," Cilacap General Hospital Director Sugeng Budi Susanto told local media.

"Cutting off a penis can be fatal."

Doctors were unable to re-attach the dismembered member because villagers could not find it.

The teen spent several days in intensive care but is now in recovery, Mr Sugeng said.

He had not spoken to anyone about the incident, Mr Sugeng said.

"He's still too shocked and embarrassed to talk to or see anyone."