Beijing on Tuesday urged its residents to not leave the city and closed schools again as authorities scramble to contain a "severe" new coronavirus outbreak in the city of 21 million people.

The coronavirus resurgence -- believed to have started in the capital's sprawling Xinfadi wholesale food market -- has prompted alarm as China had largely brought its outbreak under control through mass testing and draconian lockdowns.

The country had eased much of its anti-coronavirus measures in recent months as the government all but declared victory against the disease that emerged in the central city of Wuhan late last year.

Fearing that progress could unravel, authorities locked down several residential areas and announced new restrictions on Tuesday.

The city government said residents should avoid "non-essential travel" out of the capital.

Beijing officials said they will give virus tests to stall owners and managers at all of the city's food markets, restaurants and government agency canteens
Beijing officials said they will give virus tests to stall owners and managers at all of the city's food markets, restaurants and government agency canteens AFP / Noel Celis

"Anyone leaving Beijing must have a negative reading on a nucleic acid test taken within seven days (prior to departure)," Chen Bei, deputy secretary general of Beijing municipal government, said at a press conference.

Residents of "medium- or high-risk" areas of infection are completely banned from leaving.

The local education commission announced that all schools, which had mostly reopened, would close again and return to online classes. Universities were told to suspend the return of students.

"The epidemic situation in the capital is extremely severe," Beijing city spokesman Xu Hejian warned at a press conference.

Another 27 cases were reported on Tuesday.

Beijing's coronavirus testing capacity has been expanded to 90,000 a day, according to Xinhua
Beijing's coronavirus testing capacity has been expanded to 90,000 a day, according to Xinhua AFP / Noel Celis

They took the number of confirmed infections in Beijing over the past five days to 106, as authorities locked down almost 30 communities in the city and tested tens of thousands of people.

The World Health Organization had already expressed concern about the cluster, pointing to Beijing's size and connectivity.

Officials in the city said they would test stall owners and managers at all of its food markets, restaurants and government canteens.

Beijing's testing capacity has been expanded to 90,000 a day, according to state news agency Xinhua.

Retiree Wu Yaling, 57, was in a long queue of masked people waiting in the scorching heat for tests at a park opposite one city-centre hospital.

Map showing the districts affected in the latest flare up of COVID-19 cases in Beijing.
Map showing the districts affected in the latest flare up of COVID-19 cases in Beijing. AFP / John SAEKI

"I try not to go out as much as possible," she said, adding that her home is near one of the closed markets.

On Tuesday, the capital's transport commission banned taxi- and ride-hailing services from carrying passengers out of the city, Xinhua said.

All indoor sports and entertainment venues in Beijing were ordered to shut on Monday, while some other cities across China warned they would quarantine arrivals from the capital.

The National Health Commission also reported four new domestic infections in Hebei province, which surrounds the capital, and a case reported in Sichuan province was linked to the Beijing cluster.

Authorities were racing to track people from Beijing who had travelled to other parts of China, and encouraging those who visited the capital to get tested.

Beijing officials said Tuesday they had disinfected 276 agricultural markets and 33,000 food and beverage businesses, closing 11 markets.

Seven more residential estates were also locked down on Tuesday.

"Beijing's outbreak will probably be controlled quite quickly," said Wu Hulin, a 23-year-old tech worker in Xicheng district who got tested.

"I think (China) is doing a better job compared to overseas."

Officials had warned that, since May 30, 200,000 people had visited Xinfadi market, which supplies more than 70 percent of Beijing's fruit and vegetables.

More than 8,000 workers there had been tested and sent for quarantine.

Until the new outbreak, most of China's recent cases were nationals returning as COVID-19 spread globally.

China's Center for Disease Control and Prevention said Monday the virus type found in the Beijing outbreak was a "major epidemic strain" in Europe.

Wu Zunyou, the body's chief epidemiologist, told state broadcaster CCTV the outbreak "most likely" originated from outside China or other parts of the country.