The University of Virginia implemented new restrictions after a “troubling rise” in coronavirus cases, including the arrival of a more contagious variant, officials said Tuesday night.

The campus reported 121 new cases of the novel coronavirus Monday, according to the university’s coronavirus tracker. There are 376 active cases among faculty, staff, students and contract employees, the data show.

University leaders said the outbreak was triggered by the original strain of the coronavirus, although the campus confirmed Friday that the variant first detected in Britain also is present in the community.

The restrictions, which could last until Feb. 26, include a temporary ban on in-person gatherings, though in-person classes will continue. Officials said they will consider suspending the new restrictions if conditions improve.

Students living in residence halls will be permitted to leave their buildings only for essential activities, including attending classes, picking up meals, going to work and taking coronavirus tests, university leaders said in a message to students.

Off-campus students are encouraged to stay home and limit contact with others unless for classes or other essential activity.

Officials warned that the rest of the semester could be moved online if numbers continue rising. They also urged students to continue to wear masks and to stay at least six feet away from others.

“We do not take these actions lightly, but they are necessary at a time when the virus is more widespread, and it appears members of our community are not adhering to our health and safety protocols as consistently as they did last semester,” university leaders wrote. “This is crunch time.”

Recreational facilities also will close, and seating will be restricted in campus restaurants and dining halls. The libraries will close to visitors and offer contactless pickup.

New, more contagious variants of the novel coronavirus have been detected in the past month on several campuses, including the University of Michigan — which reported in January that three people in the Ann Arbor community tested positive for the variant first detected in Britain. One student at the University of Central Florida contracted the same strain, school officials there said Thursday.