The Boston Marathon bombing suspects had planned to blow up their remaining explosives in New York’s Times Square, pictured above, officials said Thursday.

NEW YORK — The Boston Marathon bombers were headed for New York to blow up their remaining explosives in Times Square before they were intercepted by police in a blazing gunbattle, officials said Thursday.

New York Police Commissioner Raymond Kelly said Dzhokhar Tsarnaev told interrogators from his hospital bed that he and his older brother decided on the spur of the moment last Thursday night to drive to New York and launch an attack. In their stolen SUV they had five pipe bombs and a pressure-cooker explosive like the ones that blew up at the marathon, Kelly said.

The plan fell apart when the Tsarnaev brothers got into a shootout just outside Boston that left Tamerlan Tsarnaev dead, Kelly said.

“We don’t know if we would have been able to stop the terrorists had they arrived here from Boston,” Mayor Michael Bloomberg said. “We’re just thankful that we didn’t have to find out that answer.”

Dzhokhar, 19, is charged with carrying out the Boston Marathon bombing that killed three people and wounded more than 260, and he could get the death penalty.

Christina DiIorio-Sterling, a spokeswoman for U.S. Attorney Carmen Ortiz in Boston, would not comment on whether authorities plan to add charges based on alleged plan to attack New York.

Investigators and lawmakers briefed by the FBI have said that the Tsarnaev brothers — ethnic Chechens from Russia who had lived in the U.S. for about a decade — were motivated by anger over the U.S. wars in Iraq and Afghanistan.

Based on the younger man’s interrogation and other evidence, authorities have said it appears so far that the Muslim brothers were radicalized via jihadi material on the Internet instead of by any direct contact with terrorist organizations, but they have said it is still an open question.

Dzhokhar was interrogated in his hospital room over a period of 16 hours without being read his constitutional rights. He immediately stopped talking after a magistrate judge and a representative from the U.S. Attorney’s office entered the room and gave him his Miranda warning, according to a U.S. law enforcement official and others briefed on the interrogation.

Tamerlan had come under scrutiny from the FBI, the CIA and Russian intelligence well before the Boston attack. The CIA had added Tamerlan’s name to a terrorist database 18 months ago, after Russian intelligence flagged him as a possible Muslim radical, said officials close to the investigation who spoke on condition of anonymity because they were not authorized to discuss the case publicly.

That disclosure is certain to raise questions on Capitol Hill over whether the Obama administration missed an opportunity to thwart the Boston attack.

Kelly, citing interrogations carried out by the task force investigating the Boston Marathon attack, said that days after the bombing, the Tsarnaev brothers “planned to travel to Manhattan to detonate their remaining explosives in Times Square.”

“They discussed this while driving around in a Mercedes SUV that they hijacked after they shot and killed the officer at MIT,” the police commissioner said. “That plan, however, fell apart when they realized that the vehicle they hijacked was low on gas and ordered the driver to stop at a nearby gas station.”

The driver escaped and called police, Kelly said. That set off the gunbattle and manhunt that ended a day later with Dzhokhar captured and 26-year-old Tamerlan dead.

A day earlier, Kelly said that Tsarnaev had talked about coming to New York “to party” after the attack and that there wasn’t evidence of a plot against the city. But Kelly said a later interview with the suspect turned up the information.

“He was a lot more lucid and gave more detail in the second interrogation,” Kelly said. He and the mayor were briefed on the information Wednesday night by the Joint Terrorism Task Force.

Kelly said there was no evidence New York was still a target. But in a show of force, police cruisers with blinking red lights were lined up in the middle of Times Square on Thursday afternoon, and uniformed officers stood shoulder to shoulder.

“Why are they standing like that? This is supposed to make me feel safer?” asked Elisabeth Bennecib, a tourist and legal consultant from Toulouse, France. “It makes me feel more anxious, like something bad is about to happen.”

Above the square, an electronic news ticker announced that the Boston Marathon suspects’ next target might have been Times Square.

In 2010, Times Square was targeted with a car bomb that never went off. Pakistani immigrant Faisal Shahzad had planted a bomb in an SUV, but street vendors noticed smoke and it was disabled. Shahzad was arrested as he tried to leave the country and was sentenced to life in prison.

Meanwhile, the Tsarnaev brothers’ father said Thursday that he is leaving Russia for the U.S. in the next day or two, but their mother said she was still thinking it over.

Anzor Tsarnaev has expressed a desire to go to the U.S. to find out what happened with his sons, defend his hospitalized son and, if possible, bring his older son’s body back to Russia for burial.

Their mother, Zubeidat Tsarnaeva, who was charged with shoplifting in the U.S. last summer, said she has been assured by lawyers that she would not be arrested, but was still deciding whether to go.

———

Associated Press writers Verena Dobnik and Tom Hays in New York contributed to this story.