After a gain of 0.8 percent in volume of sales in April, economists predicted a 0.2 percent for May. Instead, sales volume rose by 1.9 percent, ONS said.
The value of sales receipts also rose, climbing 3.1 percent to the highest level on record, the agency said.
The biggest boost came from non-store sales, which rose 19.1 percent from May 2012 on an seasonally adjusted basis.
Non-food sales also contributed to the increase, rising 2.2 percent from 12 months earlier.
From month to month, the quantity of sales and sales receipts rose 2.1 percent, ONS said.
Sales of goods rose 3.5 percent by quantity April to May, while the amount spent rose 3.4 percent month to month.
Only one category of retailer, general department stores, posted a decline from month to month, "showing that there was a bounce back from the weak picture seen in April," ONS said.
In the monthly survey of 5,000 retailers, the ONS said, "feedback from retailers suggested that promotions on summer ranges led to this increase in sales."
Justin Bieber crashes Drake Bell's album release party
Chipotle plans first price increase in 3 years