The ONS said so-called "shrinkflation", where the size of a product is reduced and the price stays the same, has added 1.22 percentage points to the inflation rate of the sugar, jam, syrups, chocolate and confectionery category since 2012.
The statistics agency said chocolate manufacturers had blamed the drop in size on the rising cost of raw materials.
However, the European import price of sugar sank to its lowest level on record in March this year, while cocoa prices have dropped sharply since record highs seen in 2015.
The ONS brushed aside the idea of Brexit being a key factor behind the falling size of chocolate bars.
It said: "Manufacturers' costs may also be rising because of the recent fall in the value of the pound - leading some commentators to attribute shrinkflation on the UK's decision to leave the European Union.
"But our analysis doesn't show a noticeable change following the referendum that would point towards a Brexit effect.
"Furthermore, others (including Which?) had been observing these shrinking pack sizes long before the EU referendum, and several manufacturers have denied that this is a major factor."
The statistics agency found 2,529 occasions where different types of products had changed size over the past five years, but said the difference had little impact on the headline rate of inflation.
It said the figure included products which were sampled more than once.
Toblerone made the news late last year when its US producer Mondelez International changed its distinctive mountain peak shape and made bars lighter because of rising ingredient costs.
McVities's Digestives dark chocolate biscuits have dropped in size from 332g to 300g, while the price increased by 10p to Â£1.69p in Tesco, according Which?
The consumer website said Tropicana Creations Pure Premium Orange and Raspberry juice has also decreased from 1 litre to 850ml, but the price in Asda remained at Â£2.48.