Analysis from the British Retail Consortium (BRC) and KPMG shows sales decreased by 1% last month, compared to an increase of 10.4% in June 2021.
UK households are facing the tightest squeeze since the 1970s after Inflation hit a 40-year high of 9.1% in May, with food and drink prices up 8.6%.
Discretionary purchases were hit hard, especially white goods and homeware, according to the research, while consumers also traded down to cheaper brands in food and non-food alike.
Sales across the retail sector fell 1.3% on a like-for-like basis from June last year, when they rose 6.7%.
Food sales increased 2.2% over the three months to June on a total basis and 1.6% on a like-for-like basis.
Non-food items decreased by 3.3% on a total basis and 4.2% on a like-for-like basis during the same period.
Paul Martin, UK head of retail at KPMG, said: "As the cost living crisis continues to deepen, retailers face walking a fine line between protecting margins and further denting consumer confidence by passing on price rises whilst negotiating with their suppliers to share the cost increases.
"Cost and efficiency will dominate retailers’ agendas as they are forced to make some tough decisions on which products make it to the shelves in order to remain price competitive for consumers.
"With a long run of hot weather predicted and many consumers choosing to holiday at home this summer, retailers will be hoping that the feel-good factor begins to improve confidence amongst some shoppers — as presently overall confidence levels are lower than sales may suggest."
Helen Dickinson OBE, CEO at the BRC, said: "Sales volumes are falling to a rate not seen since the depths of the pandemic, as inflation continues to bite, and households cut back spending.
"While the Jubilee weekend gave food sales a temporary boost, and fashion sales benefited from the summer holiday and wedding season, this was not enough to counter the substantial slowdown in consumer spending."
Separate figures found nearly half of people in the UK have cut back on food purchases, while others are having to spend more on their shopping as the cost of living surges.
According to the Office for National Statistics 49% of Britons bought less food than normal between 22 June and 3 July, up from just 8% when the survey began in September 2021.
Another 48% said they had needed to spend more than usual on their food shopping. Overall, 91% of people said their cost of living had risen over the past month.
The same proportion also said they had done at least one thing to reduce their energy bills.