The incident in Montauban was described as a "racist provocation" by a watchdog which monitors anti-Islamic actions in France and as an "odious and
blasphemous act" by the Montauban mayor, Brigitte Bareges.
It was the first of its kind in the southern Tarn-et-Garonne region but officials refused to speculate on a possible link to the March tragedy.
The paratroopers killed in March were two of the seven victims of Mohamed Merah, who also shot dead three Jewish schoolchildren, a rabbi and another
soldier in nearby Toulouse before being killed himself in a police siege of his apartment.
Hajii Mohamed, the imam at the mosque, told AFP the people who had left the pigs' heads had also spilled a large amount of blood on the floor of the
entrance to the mosque, which is located in a town house that has been converted to a place of worship.
"It is contemptible," the imam told AFP. "To attack a religion like this, I don't know what is happening. People lose their heads, especially during
Abdallah Zekri, the chairman of France's Islamophobia Observatory, said Wednesday's outrage occurred against the background of an increase in
anti-Muslim actions in the first half of 2012.
"For this to occur during the holy month of Ramadan, it's unspeakable," he said. "It is racist provocation."
Wednesday's incident also came hot on the heels of a controversy over the treatment of four young Muslims who were sacked for observing the Ramadan
daytime fast while looking after children on a summer camp.
The town council which had dismissed the four instructors reacted to an outcry over the issue on Tuesday by announcing that it would no longer enforce
a requirement for summer camp workers to eat and drink in the middle of the day.
French authorities have also been at odds with the biggest Islamic community in Europe over legislation which bans women from wearing full veils
while recent elections have been marked by debate over the use of halal methods of animal slaughter.