SAN FRANCISCO — San Francisco indefinitely extended its coronavirus stay-at-home and travel quarantine orders Thursday and warned residents not to gather for New Year’s with people outside their immediate households.

The city has canceled its annual fireworks celebration at the Embarcadero, and police will be assigned to places that normally attract crowds on New Year’s Eve.

Health orders have established a 10 p.m. curfew, and police said warnings and, if warranted, citations would be issued.

San Francisco police also have become aware of social media posts about private New Year’s Eve gatherings and will work with the San Francisco city attorney’s office and public health officials to try to stop them, said city police spokesman Robert Rueca.

“We are working with them as a team to address these issues,” Rueca said during an online news conference.

San Francisco and several other Bay Area counties ordered residents to stay home on Dec. 3 in hopes that the region could prevent hospital intensive care units from becoming overwhelmed.

The availability of intensive care beds in the Bay Area dipped below 15% on Dec. 17, when the state also issued a stay-home order for the region.

City officials said they did not expect the Bay Area to meet the state’s standards for lifting the order on Jan. 7, when it is set to expire.

The Bay Area’s ICU bed availability hovered at about 7.5% this week, and coronavirus cases continued to climb. Officials said it will take at least two weeks before the city knows the impact of gatherings and travel from Christmas and New Year’s.

Even when the state lifts its stay-at-home order, the city will examine its local health indicators before deciding whether to relax restrictions, officials said.

“We have been proactive in putting the stay-at-home order and travel quarantine in place to protect San Franciscans and in the hopes that by acting quickly, we could flatten the curve and re-open faster,” Mayor London Breed said in a written statement.

“This seems to be working,” she said, “but we need more time to determine that we are moving in the right direction and that the December holidays don’t set us back. There are glimmers of hope, and now is not the time to let up.”

She said on Twitter that the rate at which the virus was being transmitted had fallen from 1.45 on Dec. 5 to 1.13 on Dec. 26, meaning each infected person was passing the virus on to an average of 1.13 people.

The city’s travel quarantine discourages all nonessential travel and requires visitors to San Francisco and residents to self-isolate for 10 days if they spend any time outside the Bay Area counties of San Mateo, Santa Clara, Alameda, Contra Costa, Solano, Sonoma, Napa, Marin and Santa Cruz.

“The steps we have taken together have served us well, but the fact remains that San Francisco is in the midst of its worst surge yet,” said Dr. Grant Colfax, the city’s public health director.

During the news conference, city officials also noted that possession of fireworks, including those labeled safe and sane, remained illegal in San Francisco.

Victor Lim, external affairs officer for the city’s Department of Emergency Management, stressed that all gatherings of people outside their immediate households, including meetings outdoors, were banned.

Residents should wear masks outside their homes, distance from other people and wash their hands frequently, he said.