There were “opportunities galore” to spot that the London Bridge terror attackers were planning an outrage, an inquest at Old Bailey has heard.

Gareth Patterson QC, representing several victims’ families, outlined a number of occasions the three perpetrators had spent together and said there may have been clues they were plotting an attack. There was evidence that all three had been in contact with each other in January 2017, he said.

Patterson suggested to the inquest that it would have taken a “significant period of time” for the trio to become close enough and trust each other in planning an attack.

Khuram Butt, 27, Rachid Redouane, 30, and Youssef Zaghba, 22, launched their van and knife attack on 3 June 2017. Eight people, Xavier Thomas, 45, Christine Archibald, 30, Sara Zelenak, 21, Sebastien Belanger, 36, James McMullan, 32, Kirsty Boden, 28, Alexandre Pigeard, 26, and Ignacio Echeverria, 39, were killed and another 48 people injured in an assault that lasted less than 10 minutes.

Patterson said all three had been at the Ummah fitness centre in east London in March, they had all been at the same address at some point and Butt had possibly been trying to buy a gun.

Acting DCI Wayne Jolley, the investigating officer, said he did not agree that there had been missed opportunities surrounding the men and said police would have been working with the intelligence they had.

Patterson pointed to the repeated contact between the men, including a barbecue at Butt’s home in May. He said Butt and Redouane had been in contact “again and again for months”, including at the gym and by phone. He also noted that Redouane had bought three identical knives the day after the barbecue.

Patterson said: “Any reasonably competent investigation should have been looking at Redouane at this stage, I would submit.” Jolley told the court: “Again, that would depend on the intelligence at that time.”

The inquest heard that Zaghba had been going to Butt’s gym since January and had been in phone contact with him since then. He had also been at Butt’s home and was allowed to drive his car. Patterson said: “All of these things, when pulled together, I would suggest, is crying out to be looked at.”

He told the court that all three men were at the gym in May “in the dead of night, speaking together in the street” in what he described as a highly suspicious conversation.

Patterson noted that a phone was placed on the ground before the men began walking and talking during that meeting. He described this as a “classic anti-surveillance technique” and suggested “the attack planning was there to be detected”. He added: “A reasonably competent surveillance, I would suggest, would have had Butt monitored up to that point.”

The court was told that Zaghba had held extremist views since childhood. He celebrated the 11 September 2001 attacks and had Islamic State flags on his Facebook page, according to writings by his mother. He tried to fly abroad to fight for Isis and jihadist material was found on an SD memory card that was seized from him when he was stopped at an airport.

The inquest continues.