Consumer prices rose by a slightly bigger-than-expected 0.2 percent in June on higher food costs and they were up by the same amount after stripping out volatile food and energy prices, the Labor Department reported on Wednesday.

Last month's gain in the Consumer Price Index was slightly larger than the 0.1 percent advance Wall Street economists were expecting to see after a fall-off in energy prices. But the increase in the more closely watched core prices index was directly in line with expectations.

On balance the numbers show inflation is relatively contained, said Omer Esiner, foreign exchange market analyst with Ruesch International in Washington.

U.S. government bond prices rose slightly on Wednesday after the June Consumer Price Index came in much as expected, while separate Commerce Department data on the housing market was mixed. The dollar inched up against the euro.

But investors were expected to react more to testimony to Congress expected later on Wednesday from Federal Reserve Chairman Ben Bernanke, in his twice-a-year assessment of the economy.

In the Labor report, food prices advanced 0.5 percent in June, continuing a string of increases. They contributed 17 percent to the overall CPI increase in the first half of this year. Energy prices were down 0.5 percent last month, but the Labor Department said for the first half of this year, they advanced at a 27.8 percent seasonally adjusted annual rate and accounted for about 48 percent of the advance in the overall


Ex-food, ex-energy prices were up 2.2 percent from the same time a year ago, this was in line with expectations. The overall CPI was up 2.7 percent from a year ago, slightly more than the 2.6 percent advance economists were expecting.

So far this year, the core CPI has advanced at a 2.3 percent seasonally adjusted annual rate, compared with a 2.6 percent rise for all of 2006.