Producer prices rose at their fastest pace in five months in September as the cost of gasoline surged, but a small gain in core prices suggested the increased price pressure was unlikely to be sustained.

The Labor Department said on Tuesday its seasonally adjusted index for prices received by farms, factories and refineries, increased 0.8 percent after being flat in August. Economists had expected prices to increase 0.2 percent.

Stripping out volatile food and energy, wholesale prices rose 0.2 percent after inching up 0.1 percent in August.

Slower growth abroad suggests further moderation in demand for raw materials heading into the fourth quarter, which will likely translate into inflation moderation, said Lindsey Piegza, an economist at FTN Financial in New York.

Prices for U.S. government debt trimmed gains on the data.

The dollar briefly pared gains against the euro, while stocks on Wall Street were lower as investors focused on Moody's warning on France's credit rating and slow growth in China.

Gasoline prices jumped 4.2 percent, the largest gain since March, after dropping 1 percent in August.

Economists, however, dismissed the spike in gasoline, saying it was attributed to how the data was adjusted to try to smooth seasonal volatility.

It probably did not point to a new trend to higher inflation, said Gary Thayer, chief macro strategist at Wells Fargo Advisors in St. Louis, Missouri.

But some said there was a risk that data on Wednesday could show an upside surprise in September consumer prices.

The consumer price index likely rose 0.3 percent last month, according to a Reuters survey, after increasing 0.4 percent in August.

INFLATION SEEN CONTAINED

The strong rise in wholesale prices last month is unlikely to spark a broad increase in inflation pressures given the weak economic environment.

It will probably have little impact on the Federal Reserve, which focuses on core consumer inflation, as it weighs further options to help the anemic recovery and pull down an unemployment rate stuck above 9 percent.

Pressure on the U.S. central bank for further monetary stimulus has lessened in recent weeks as retail sales and the trade balance data suggested economic growth accelerated in the third quarter after the second quarter's tepid 1.3 percent annual rate.

Economists estimate gross domestic product grew at an annual pace of anywhere between 2.3 percent and 2.7 percent in the third quarter.

The economy's improving tone is starting to filter through to the ailing housing market. Home-builder sentiment rose this month to its highest level in nearly 1-1/2 years, the National Association of Home Builders said in a separate report.

The NAHB/Wells Fargo Housing Market index rose to 18, the highest level since May 2010, from 14 in September. Economists had expected the index to only rise to 15.

Still it remained below 50, meaning more builders view market conditions as poor.

Last month, food prices rose 0.6 percent, slowing from a 1.1 percent rise in August.

In the 12 months to September, producer prices increased 6.9 percent, accelerating from August's 6.5 percent advance.

Wholesale prices outside of food and fuel were bumped up by a 0.6 percent rise in light motor trucks -- accounting for a third of the rise in the core PPI measure. Light trucks had risen 0.1 percent in August.

Passenger car prices fell 0.5 percent after slipping 0.4 percent in August. Disruptions to production wrought by the March earthquake in Japan caused car prices to spike early this year.

In the 12 months to September, core producer prices rose 2.5 percent after increasing by a similar margin the prior month. The rise was above economists' expectations for a 2.4 percent advance.

(Additional reporting by Ellen Freilich in New York; Editing by Neil Stempleman)