Italy's justice ministry has ordered a preliminary inquiry into an appeals court ruling that overturned a rape verdict on the grounds that the victim was too ugly to be raped.

The ruling has sparked outrage in Italy, including a demonstration on Monday outside the Ancona court where protesters shouted "Shame!" and held up signs saying "indignation".

The appeals sentence was handed down in 2017 - by an all-female panel - but the reasons behind it only emerged when Italy's high court annulled it on March 5 and ordered a retrial.

The Court of Cassation said on Wednesday its own reasons for ordering the retrial will be issued next month.

The Justice Ministry says two Peruvian men convicted in the 2015 assault successfully argued the woman was too "masculine" to be a victim.