The food index also rose 0.4 percent in July after rising 0.2percent in June.
The index for meats, poultry, fish and eggs increased 0.5 percent to 224.6, while the index for food at home rose 0.6 percent to 227.1.
Five of the six major grocery store food groups increased during July, led by a 1.2 percent gain in both the dairy and related products index and the fruits and vegetables index.
The index for dairy and related products was 214.8 in July, which was up from 212.3 in June.
The 1.2 percent gain in the index for fruits and vegetables followed declines of 0.3 percent and 1.3 percent in June and May, respectively. The BLS attributed the July gain to a 3.7 percent increase in the index for fresh fruits.
The index for nonalcoholic beverages increased 0.9 percent in July as the coffee index continued to rise sharply, the BLS said.
The index for other food at home was up 0.3 percent to 197.7, and the index for food away from home rose 0.2 percent to 231.6.
The lone major food index to decline during July was cereals and bakery products, which eased 0.1 percent to 259.6.
The overall Consumer Price Index rebounded from a decline of 0.2 percent in June by increasing 0.5 percent in July to 225.4. The index now has increased 3.6 percent over the past 12 months.