Attaporn Boonmakchuay said the python was “yanking very hard” as he and his wife tried to wrestle it off.
Doctors said Mr Attaporn, who lost a lot of blood in the ordeal, was making a good recovery.
Workers dismantled the toilet and extracted the python which had slithered through domestic plumbing.
It was released back into the wild.
The incident happened as Mr Attaporn, 38, went to the toilet at his home in Chachoengsao province, east of Bangkok, before leaving for work. As he used the toilet he said he suddenly felt a sharp pain.
“I felt as though my penis had been severed. The snake was yanking very hard,” he said, according to the Bangkok Post.
As the python tried to pull him down, he called for his wife and neighbours to help him, the post reported. Mr Attaporn told Thai TV that his wife tied a rope around the snake and he pried its jaws open before passing out from blood loss.
Doctors said Mr Attaporn was recovering well. “He has a really good attitude… even though his own wife and children were in shock. He’s been smiling and giving interviews all day from his bed,” said Chularat Hospital director Dr Chutima Pincharoen.
Mr Attaporn said he planned to replace the squat toilet with a sitting one.