In a tweet on Monday (Sept 3) evening, Khairy said that public caning should not have been carried out.
“There are many other ways to handle LGBT issues. Although it is enshrined in the law, it is unfair to enforce public caning in the public eye,” he tweeted from his @Khairykj handle.
He added that Islam teaches to look after the dignity of every human being: “And that mercy is preferable to punishment.”
Earlier, the two women pleaded guilty to attempting to have same-sex relations and were caned six times at the Syariah High Court in Terengganu on Monday.
The sentence was conducted behind closed doors in the courtroom after it was read out by Syariah High Court judge Kamalruazmi Ismail.
It was also witnessed by state Syariah chief judge Wan Mohd Zakri Wan Mohd and state senior Syariah judge Rosdi Harun.
The accused, aged 22 and 32, were led to a stool where two female officers from the Kajang Women's prison carried out the sentence in turns.
However, the younger woman, aged 22, started to sob when the cane hit her.
Observers also noticed that this time, the force was slightly stronger than the one applied on the older woman.
Syariah caning is not similar to civil whippings, in that it is not meant to hurt, and the cane should not be swung from a level above the head.
The officer carrying out the sentence was also advised to cane the accused at her own time or pace using only medium force.
The whole session was over in six minutes.
About 150 people were present in the courtroom and among them were state Exco chairman of Syariah implementation, education and higher education Satiful Bahri Mamat, Kuala Terengganu MP Ahmad Amzad Hashim and state Assembly Speaker Yahaya Ali.
The women were supposed to have been caned on Aug 28 but had their sentence postponed to Monday.
On Aug 12, the Syariah High Court fined the women RM3,300 and ordered that they be caned six times each after they pleaded guilty to committing musahaqah (sexual relations between women) under Section 30 of the Syariah Criminal Offences Enactment (Takzir) (Terengganu).
The sentence drew the ire of many human rights groups, including the Human Rights Commission of Malaysia (Suhakam).