MANILA — President Rodrigo Duterte of the Philippines has admitted to sexually assaulting a housemaid when he was a teenager in a speech that drew condemnation from women’s groups, but which his office later dismissed as a joke.

Mr. Duterte has made headlines around the world for remarks that run the gamut from innocuously bawdy to dangerously sexist, including jokes about rape. His speech on Saturday to local officials, however, appeared to be the first time in which he publicly admitted to personally assaulting a woman.

In a speech that focused his ire on the Roman Catholic Church — a powerful political foil in this predominately Catholic country — and what the president sees as its hypocrisy, Mr. Duterte recounted a confession he made to a priest about entering the bedroom of a maid and assaulting her.

“I lifted the blanket,” Mr. Duterte, 73, said. “I tried to touch what was inside the panties.”

“I was touching. She woke up. So I left the room,” he added.