Cairo: An Egyptian court has sentenced a man to death by hanging after convicting him of sexually assaulting a 20-month-old child in a crime that shocked the conservative country.

The decision was issued by the Criminal Court in the Nile Delta province of Dakahlia following the second session of the trial that started last month, legal sources said.

The 35-year-old convict was also found guilty of kidnapping the toddler from outside her house where she was playing in the Nile village of Damlash, north of Cairo.

He confessed to the attack and told the court he was “under the influence of the devil.” The convict, identified as Ebrahim Al Refai, expressed regrets, the sources added.

As chief judge Mokhtar Shalabi declared the verdict, the audience in the coutroom erupted in cheers and chanted “long live justice”.

The ruling will now be referred to the grand mufti, the country’s highest Islamic authority to approve or reject it, a routine procedure in death sentences in Egypt.

The final verdict will be announced on June 2.

Security was tightened inside and outside the court house in anticipation of backlash by the victim’s relatives against the convict and his family. No violence was reported.

The case dates back to late March when Al Refai carried the child to a deserted place where he sexually assaulted her, witnesses said. The victim is believed to be the youngest ever child subjected to a sex offence reported in Egypt.

She suffered a severe bleeding as a result and was taken to a local hospital for emergency surgery.

The province’s governor ordered psychological counselling for the child and her family.

The incident sparked outrage in the Egyptian media, which branded it the “diaper rape.”

Rights advocates also denounced the assault and demanded tougher penalties against assailants of children.

In recent months, Egyptian courts have issued tough jail sentences in cases of sex assaults.

The verdicts were delivered following a short number of hearings. Previously, such cases took long years before a ruling was delivered.