China's inflation rose in June but was well below the government's target in a sign of weak demand amid an economic slowdown.

Consumer prices rose 2.7% over a year earlier, up from May's 2.1% gain but below the 3.5% official target for the year, the government said today. The June figure was driven by a 4.9% rise in food costs.

Pressure for prices to rise is relatively low in China because of weak demand, excess production capacity in many industries and lower costs for raw materials and components.

June prices were unchanged from May levels, and the move upwards of the inflation rate was due to comparison with unusually low prices last year, analysts said.

Economic growth slowed to 7.7% in China in the first quarter of this year from the previous quarter's 7.9%. Some forecasters say it could dip below 7% in coming quarters due to government efforts to cool a credit boom and weak demand for Chinese exports.

Communist leaders are trying to shift the basis of China's economic growth from exports and investment to domestic consumption. They have refrained from launching new stimulus spending even as economic growth drifted down.

Producer prices declined 2.7% in June compared with a year earlier, the National Bureau of Statistics reported. That was driven by an 8.5% fall in the price of goods from the mining industry and weaker costs for other industrial raw materials