BEIJING — The Apple stores were among the busiest places still open in Beijing after the coronavirus outbreak, though employees forbade customers to try the watches or AirPods.

Some people ventured in out of necessity, as ever. “My laptop is broken,” one woman said. For others they provided a rare communal gathering space, a break from the isolation, anxiety and fear that have settled on the city of 23 million ever since the epidemic began to emanate from central China.

Now the stores have closed, along with theaters, museums, cinemas, temples, barbers, hair salons, karaoke bars, and most other shops and restaurants. The Forbidden City has shut down “until further notice,” as has a popular section of the Great Wall in the breezy, wintry hills to the northeast, far from urban congestion.