New York City's annual Fourth of July celebration will go on "one way or another," Mayor Bill de Blasio said Wednesday.

"There's no day like the 4th of July, it's special. Even if we have to do something different, we have to mark it in a very meaningful way, especially at this moment where everyone's fighting shoulder to shoulder to get through this disease," de Blasio said at a press conference.

De Blasio said he spoke to Macy's CEO Jeffrey Gennette this week and agreed to host the celebration, although it may look different than in years past. He said that there will definitely be fireworks, although they city is still deliberating how and where they will be done.

https://twitter.com/NYCMayor/status/1252945537701220352

New Yorkers will likely have to adhere to social distancing guidelines "for quite a while," but this is a day that the city can't miss, de Blasio said. He said more details will be released later.

"Since 1976, Macy's Fireworks have lit the skies over many of New York City's waterways and neighborhoods. Together with our partners in the City of New York, we are reimagining how to safely share the nation's largest 4th of July fireworks show with America again this year," a Macy's spokesperson said.

"This year's show will be a celebration of the strength and resilience of New York City and will honor frontline workers across America," he said.

On Monday, de Blasio announced the city is canceling concerts, festivals and parades, including the 2020 Pride march, through June. The city had previously canceled nonessential events through May, saying that public health officials and infectious disease experts are still unsure how the next few months will play out.

He said that although the city has seen progress in containing the coronavirus, more progress will need to be made in order to reduce the virus' spread and begin easing restrictions.

There's still widespread transmission throughout the city, meaning that health officials aren't able to trace the origin of most Covid-19 cases and residents need to maintain social distancing to contain the outbreak, de Blasio said.

— CNBC's Lauren Thomas contributed to this report.