Consumer prices in Morocco fell year-on-year in October, their second drop this year, due mostly to cheaper food, official data showed on Friday.

A surge in food and education costs had pushed the consumer price index to a year-high in August when it hit 2.2 percent but it quickly eased to 0.8 in September and the country stopped grain imports after its local harvest rose by almost 18 percent.

Compared with their level a year earlier, consumer food prices fell 1.1 in October, data from the state's High Planning Commission (HCP) showed.

Underlying inflation, a gauge used by Morocco's central bank to set the benchmark interest rate that excludes state tariffs and volatile prices, rose by an annual 1.1 percent in October against 1.4 percent in September.