Compared to July 2012, sales volumes rose 3 percent, the data office said.
Food sales rose 2.1 percent from July 2012, the biggest increase since April 2011.
Supermarkets reported summer weather helped push sales of outdoor items, beverages, clothing and alcohol, the report said. Sales volume in supermarkets alone rose 2.5 percent, a "strong" gain, ONS said.
From June to July, sales rose 1.1 percent, steeper than the 0.6 percent economists had predicted.
It was the third consecutive month data topped expectations.
ONS said retail prices for goods rose by 1.8 percent from July 2012, mainly due to higher food prices.
Retail receipts per week came to $10.88 in July, up from $10.5 billion in June, $10.33 billion in May and $10 billion in June 2012, the data office said.
Average weekly sales were also higher than July 2012 when receipts averaged $10.4 billion per week.
Swim Week Miami Beach 2014 [PHOTOS]