U.S. import prices were unexpectedly flat in July as a surge in the cost of fuels was offset by weak prices elsewhere, suggesting a strong dollar was keeping imported inflation pressures in check.

The Labor Department said on Tuesday the unchanged reading in import prices last month followed an upwardly revised 0.1 percent drop in June. Import prices were previously reported to have declined 0.4 percent in June.

Economists polled by Reuters had forecast import prices gaining 0.1 percent in July.

In the 12 months through July, import prices rose 4.8 percent, the largest gain since February 2012, after increasing 4.7 percent in June

Last month, prices for imported fuels and lubricants jumped 1.6 percent after rising 1.3 percent in June. Food prices dropped 1.8 percent after declining 2.6 percent in June. Excluding fuels and food, import prices slipped 0.1 percent in July after falling 0.2 percent in the prior month.

The so-called core import prices increased 1.6 percent in the 12 months through July. The monthly drop in core import prices likely reflects the dollar's 0.5 percent appreciation against the currencies of the United States' main trading partners in July.