The incident occurred in the town of Sidi Boulaalam in Essaouira province. The aid was being handed out by a private local charity.
Some reports indicate that up to 40 people were injured in the crush. Local media reported that most of the victims were women and elderly people.
Pictures on social media showed bodies of women laid out on the ground.
Witnesses told local media that this year’s annual food aid distribution at a local market in Sidi Boulaalam, an impoverished town with just over 8,000 inhabitants, attracted a larger crown that usual.
“This year there were lots of people, several hundred people,” a witness who asked to remain anonymous told AFP news agency.
“People shoved, they broke down the barriers,” he said, adding that the injured had been evacuated to a hospital in Marrakesh.
Morocco’s interior ministry said that King Muhammed VI had instructed the local authorities to help those affected, adding that he would personally cover all medical and funeral costs.
An unverified video shot by a bystander before the incident showed a large crowd gathered at the open-air market, waiting for the food distribution.
It is not clear what triggered the stampede. (Courtesy BBC)