Food prices increased across the board, led by fruit and vegetables, which increased 10 percent annually.
Higher dairy prices were also a major contributor.
"Average prices for grocery food items like yoghurt, milk, and cheese were all notably higher than they were in May 2021," consumer prices manager Katrina Dewbery said.
For the 12-month period, grocery food prices increased 7.4 percent, restaurant meals and ready-to-eat food prices increased 6.0 percent, meat, poultry, and fish prices increased 7.0 percent and non-alcoholic beverage prices increased 2.7 percent.
The annual rate of food price inflation was higher than the 6.4 percent rise in April 2022 compared with April 2021.
The big increases suggested overall Consumer Price Index inflation was likely still rising, ASB senior economist Mark Smith said.
"All up, annual NZ CPI inflation looks like it will move above 7 percent in the June 2022 year."
There was a "clear risk that high inflation outcomes prove to be more persistent than earlier envisaged," he said.
This would trouble the RBNZ and could mean a more aggressive signalled pace of OCR hikes despite a weaker backdrop for economic activity, he said.
Monthly food prices were 0.7 percent higher in May 2022 compared with April.
A 1.1 percent rise in grocery food prices was the largest contributor to the monthly movement, led by an increase in yoghurt prices.
"Many dairy items have seen price increases over the past month," Dewbery said.
"Yoghurt has seen the largest increase, with the weighted average price of a six-pack of yoghurt increasing from $5.60 to $6.40."
"Other consumer dairy items that have increased in price included butter, milk, and cheese. We have also seen increases in prices paid for dairy manufacturers' goods and services in our producer's price index."
The supermarket sector has been in the spotlight this year.
A Commerce Commission market study into the industry, published in March, revealed the extent of New Zealand's duopoly in the supermarket sector- led by giants Countdown and Foodstuffs.
The Commission estimated Countdown and Foodstuffs were making excess profits of about $430 million a year - more than $1m a day.
In response, the Government put the duopoly on notice, warning the sector to change "at pace" or face regulation.
The Government said it will be acting on a lack of competition, which could pave the way for other players.
Both Countdown and Foodstuffs have since announced price freezes on hundreds of everyday products.
Foodstuffs - which owns Pak'nSave, New World and Four Square - has cut the price of food by an average 10 percent on more than 100 groceries.
Foodstuffs said the reductions were expected to result in weekly savings of $500,000 for shoppers.
Countdown has put a winter price freeze on 500 items no matter what happens with inflation.
Items include essential lines across butter, cheese, sugar, flour and rice.
In the year to September 2021, New Zealanders spent more than $22 billion at supermarkets and grocery stores in this country.