NEW YORK — A man who drove his car into the Chabad Lubavitch world headquarters in Brooklyn was charged with attempted assault as a hate crime, New York police said Thursday, as investigators continued to look for what prompted the crash.

Police said the suspect, Dan Sohail, 36, rammed his car repeatedly into doors at the Hasidic Jewish center on Wednesday night. Investigators were still trying to piece together what prompted him to drive into the building, according to the police briefing.

At Thursday’s news conference, New York Police Department Chief of Detectives Joseph Kenny said Sohail had recently been trying to connect with the Lubavitch Jewish community. Kenny said “Earlier this month, Sohail attended a social gathering at this very same location,” and that there was video circulating online of that gathering.

Kenny said the video appears to show Sohail dancing with Orthodox men inside the headquarters. He added that police believe Sohail was in Brooklyn the night of the crash to continue “this attempt to connect with the Lubavitch Jewish community,” and said he was recorded dancing with congregants during a recent visit.

Police said Sohail told them he lost control of his car because he was wearing “clunky boots,” Kenny said. Kenny also said Sohail removed several blockades and cleared snow away from a sidewalk before driving into the building.

Police said no one was injured and some doors were damaged. They said no weapons were discovered in Sohail’s car, and that the complex at 770 Eastern Parkway—home to a synagogue and offices—was packed with worshippers when the crash occurred.

The incident occurred on the 75th anniversary of Rabbi Menachem Mendel Schneerson becoming the leader of the Lubavitch movement, prompting swift concern from city officials. Mayor Zohran Mamdani and Police Commissioner Jessica Tisch rushed to the scene to brief media, and officials announced increased security around houses of worship across New York.

Mamdani said, “This is deeply alarming, especially given the deep meaning and the history of the institution to so many in New York and around the world,” adding: “And on today of all days.”

Sohail’s father told the New York Daily News that his son had been considering converting to Judaism and had struggled with “mental problems,” the Associated Press reported. The Forward, a Jewish-focused media outlet, interviewed a rabbi in New Jersey who said Sohail attended a Purim service at Chabad last year and visited two other times seeking spiritual guidance.

The Forward quoted Rabbi Levi Azimov as saying he talked to Sohail briefly and saw “he’s not exactly stable.” The Forward also reported that another rabbi at a Jewish school in Carteret, New Jersey, where Sohail lived, said Sohail dropped by for afternoon prayers on Tuesday but began yelling about feeling let down by Chabad after the service.

The Chabad headquarters and synagogue draws thousands of visitors each year, and the complex has a near constant police presence, according to the report.