Marks & Spencer’s online sales slumped as it was forced to close its website due to the effects of the cyber attack, which gave opportunity to rivals like Next, Zara and H&M.

Clothing sales at M&S slumped by a fifth in the four weeks to May 25, compared with the same period a year before, after it was forced to stop taking orders on its ecommerce website, according to the latest figures from Kantar.

Sales had soared 11.5% in the previous three months, however, M&S was forced to stop trading on its website on April 25, as a result of the cyber-attack. The retailer was only able to restart trading on June 10 – missing out on crucial weeks of summer sales.

Across the wider fashion industry, sales grew 4% during the four week period to May 25, up from 1% growth in the previous month.

However, despite losing out in online sales, M&S customers still came into stores and helped keep the brand from losing too much market share to its rivals during the period.

M&S sales growth fell to 1% while its website was down, from 11.5% in the period before. By contrast, Next brand sales growth rose to 4.8% from 1.6%, according to analysis from Jefferies.

Zara sales growth rose to 27.8% from 16.1% in the prior month, while H&M saw jumped 18.1% from 8.9% previously.

Primark by contrast, which doesn’t offer an ecommerce website for customers, didn’t see any sales migration from M&S customers, with relatively flat sales growth for the period.

M&S said the cyber attack was “a moment in time”, and its stores had performed well “across all fashion categories and particularly womenswear” when orders on its website were paused.

“This underlines the strength of our product offer – where quality and value perceptions remain market-leading and style perceptions continuing to increase – and loyalty of our customers. A big thank you to them for shopping with us.”