The authorities said yesterday they had foiled a plan to wage jihad, or "holy war", against the United States by detonating bombs outside a pair of synagogues in New York and using a stinger missile to shoot down National Guard aircraft at a base in Newburgh about 60 miles north of the city.

Capping a surveillance operation that began a year ago, agents arrested four men late on Wednesday night as they planted what they thought were homemade bombs outside the two synagogues in the Bronx neighbourhood of New York City. The bombs had in fact been made by undercover FBI officers and were harmless.

There was no doubting what the men were hoping to achieve, one police source suggested – to detonate "a fireball that would make the country gasp" in the city that had suffered so much destruction at the hands of terrorists in September 2001.

Download the new Independent Premium app Sharing the full story, not just the headlines

Four men were allegedly involved in the Bronx plot. Three were due in court later yesterday to face conspiracy charges while a fourth was being treated for an undisclosed illness and would be brought before a judge later. If convicted, all four men, three Americans and one Haitian, could face life in prison, officials said. They added that three of the men were converts to Islam.

Speaking to reporters at the Riverdale Jewish Centre, one of the targets of the alleged plot, the New York Police Commissioner Raymond Kelly said yesterday that the four men were small-time criminals who had become acquainted with each other in the first place though prison contacts. They were identified as James Cromitie, David Williams, Onta Williams and Laguerre Payen. Mr Cromitie was the oldest member of the group.

"They stated that they wanted to commit jihad," Mr Kelly said. "They were disturbed about what was happening in Afghanistan and Pakistan, that Muslims were being killed. They were making statements that Jews were killed in this attack and that would be all right – that sort of thing."

All four men were snatched on Wednesday evening in the Riverdale area of the Bronx just as one of the band had placed the fake bombs outside the targets. Mr Kelly said that a large articulated policy lorry was used to block the road as agents swooped in to arrest and handcuff the men. A fifth man who was behind the wheel of the getaway car was in fact an undercover FBI informer, he revealed.

The state assemblyman from Riverdale, Jeffrey Dinowitz, spoke of the shock felt across the neighbourhood yesterday. "I think most people will agree that we're very angry, but very sad that this kind of plot would take place in our community," he said. "There are people out there motivated by religious hatred, hatred against Jews frankly, but the good news is that the NYPD and FBI were on top of this from the very beginning."

Mixed emotions were expressed by the director of the Jewish Centre, David Winter. Saying he was both "shocked and relieved", he added: "Instead of a terrible story, it's a story of success." The two targeted Jewish temples were just a few blocks apart and the mock bombs were placed in car boots at each location.

Police officials said that the accused men thought that they were planting 37lb devices. However, in each case they were packed with inert C-4 plastic explosives prepared by the FBI. Each of them had been "totally disabled" and "there was no danger to anyone," Mr Kelly said.

The undercover operation to track the activities of the men started in June last year in Newburgh, on the Hudson river, where the accused men lived. The undercover FBI agent convinced the accused men that he was connected to a known terrorist group in Pakistan known as Jaish-e-Mohammed.

By October, the undercover FBI agent began inviting the men to a house in Newburgh to discuss moving their plot forward. The house was equipped with video cameras. Material recorded there will now form the basis of the prosecution.