Shortages of food and medicine have left residents in China’s biggest city desperate and frustrated as authorities struggle to gain control of a Covid-19 outbreak.

Shanghai, which has been forced to follow Beijing’s tough “dynamic zero” Covid strategy, implemented two four-day lockdowns of each side of Huangpu river. But as the caseload of the infectious Omicron variant rose rapidly, authorities extended restrictions on parts of the eastern Pudong area, which includes the city’s financial district.

Cries for help littered social media this weekend before being deleted by censors, as the city’s case count overtook that of Hong Kong, which recorded the world’s highest fatality rate in March.

Residents on social media said online grocery stores had run out of food while others complained that they could not buy their regular medication. “Who can tell me how to get medicine? I am so hopeless. I want to leave Shanghai,” said one resident.

Some Shanghainese, who have been unable to leave their homes for more than two weeks owing to restrictions that predated the lockdown because of positive cases in their buildings, have relied on government grocery deliveries.

Parents also pleaded for help after being separated from their young children if they or their child tested positive. Zeng Qun, deputy head of the Shanghai Civil Affairs Bureau, said temporary guardians would be found for children who were not infected but were forced to stay at home alone after their parents were sent to quarantine centres, state media reported.

EU nations last week called on local authorities to stop separating children from their parents and to ensure appropriate care for those facing non-Covid emergency medical issues.

In a reflection of how contentious the country’s elimination policy has grown, a recorded conversation, allegedly between a Shanghai health official and a resident, was widely shared.

The official complained about politicised decision making and that the government had ignored health professional recommendations and was isolating asymptomatic patients. The Financial Times has been unable to verify the veracity of the recording.

In Hong Kong, the isolation of mild and asymptomatic cases clogged hospitals and exacerbated the strain on the healthcare system.

On Saturday, Sun Chunlan, a Chinese vice-premier, visited Shanghai and urged the city to stick to the zero-Covid strategy and expand isolation facilities.

“It is an arduous task and huge challenge to combat the Omicron variant while maintaining the normal operation of core functions in a megacity with a population of 25mn,” Sun said.

Shanghai authorities on Sunday reported that 8,226 cases had been detected on Saturday, taking the total to 51,180 infections since the outbreak began in the beginning of March.

In Hong Kong, chief executive Carrie Lam said that all residents would be asked to perform Covid-19 rapid antigen tests at home on April 8, 9 and 10 in an attempt to uncover asymptomatic cases.

While the number of cases are far below those recorded in the rest of the world, the outbreak threatens Beijing’s efforts to eliminate the virus inside China and prevent disruption to the economy. Low vaccination rates among the very elderly, coupled with no previous exposure to the virus, mean that the country risks a much higher death rate if the outbreak is not contained.