LONDON — Following a fast-moving investigation and manhunt, British police on Saturday morning arrested an 18-year-old man in connection with the attack on the London subway that injured at least 29 people in what police called a terrorist incident.

Authorities said the man has been arrested by Kent police in the port area of Dover on the English Channel.

Deputy Assistant Police Commissioner Neil Basu called the operation a “significant arrest.” He said the investigation is ongoing.

The man is being held for questioning under the Terrorism Act. “For strong investigative reasons we will not give any more details on the man we arrested at this stage,” Basu said.

A homemade bomb exploded on a London subway train at Parsons Green station Friday morning, sending a scorching blast of flame and smoke through a London subway car.

On Saturday morning, security measures remained tightened across London’s vast mass-transit network, and the government described the threat level as critical, meaning another attack could be imminent.

British media reported that the crude explosive device, carried in a bucket and shoved into a shopping bag, had a timer, suggesting that some degree of bombmaking knowledge was employed.

The Islamic State terrorist group asserted responsibility for the explosion on its Amaq News Agency website. Experts cautioned that the group often seeks credit for attacks it may have only inspired, as well as ones it had nothing to do with.

The explosion on London’s Tube is bound to rekindle pointed debate about whether countries such as Britain have been tough enough in fighting terrorism. Just hours after the blast, President Trump suggested that Britain needed to be “more proactive.” Shortly after, Prime Minister Theresa May retorted that such criticism was not helpful.

“This was a device intended to cause significant harm,” May said, but it remained unclear whether the explosive may have detonated prematurely or malfunctioned at the Parsons Green station, about three miles southwest of central London.

It was not certain whether the bomber was among those hurt or was now on the run. In a sign that a manhunt could be mobilized, London police appealed to the public to submit cellphone images taken at the scene. British media said that investigators had images of a suspect from closed-circuit television. The homemade device blew up on the inbound train, nine stops from Westminster, the seat of the British government.

After the attack, Trump tweeted: “Another attack in London by a loser terrorist. These are sick and demented people who were in the sights of Scotland Yard. Must be proactive!”

It was unclear whether Trump had been briefed by his security advisers and knew something of the identity of the assailants. At the time, neither the London police nor the British government had said anything publicly beyond describing the detonation as a suspected terrorist attack.

Following Trump’s tweets, and without mentioning the American president by name, May said that it’s not “helpful for anybody to speculate on . . . an ongoing investigation.”

Later, during a brief appearance outside the White House, Trump further hammered a hard-line message, saying: “We have to be very smart and we have to be very, very tough — perhaps we’re not nearly tough enough.”

Trump later called May to “convey his sympathies and prayers for those injured” and “pledged to continue close collaboration” with Britain to stop such attacks worldwide, the White House said in a statement.

During a tumultuous election campaign that was interrupted by two terrorist attacks, the British prime minister repeatedly promised harsh new measures. May vowed that “if human rights laws get in the way” of protecting Britain, she would change those laws.

At the time, experts wondered whether May’s tough talk could be matched by more action in a country considered one of the world’s most proactive on counterterrorism.

“The threat is now so diffuse that it is unclear how those measures could be more effectively used to prevent future attacks,” said Raffaello Pantucci, director of the International Security Studies group at the Royal United Services Institute in London. “One of the few possibilities would be to impose harsher sentences for terror-related offenses, and that is certainly something being considered.”

“There are only so many things you can do, though,” he said. “I don’t think Britons would want to have armed police officers on every street corner.”

Parsons Green is in Fulham, a neighborhood of Victorian rowhouses and leafy parks known for its furniture designers and Champions League soccer.

Witnesses described a fireball and smoke racing through the subway car, and then a frantic crush of people trying to flee while others attempted to aid those with burns and other injuries.

Luke Walmsley, 33, a film editor, was on his way to work during a normal morning commute, listening to music. And then things were suddenly not normal.

“I heard a scream and then there was a flash, a light and smoke. I actually pulled my earplugs out, and then the screams got louder and louder,” he said, recalling people running toward him at the station.

“It was chaos. It was every man for himself to get down the stairs, and it’s a very tight exit,” he said, describing injured people on the ground. “I went back to see if they were okay. Other people attended them, then there were nannies and moms asking where their children were.”

He said people were helping others “who were shocked and burned, bottles of water being poured over burns, quite severe burns, whole legs.”

In the months since May’s narrow reelection, her government has come up with few new security proposals. Cities have invested in erecting barriers or bollards to make it harder for terrorists to attack popular public spaces. Earlier this week, London police deployed for the first time new high-tech nets laced with tungsten-steel spurs that can be placed on roadways to stop marauding vehicles as heavy as a double-decker bus.

“The terrorist threat now includes unsophisticated attacks, such as stabbings and vehicle ramming, where the planning ­cycle is much shorter than it would otherwise be,” said Rajan Basra, a researcher with the International Center for the Study of Radicalization, at King’s College in London. “This volatility means that the authorities have to intervene a lot earlier.”

Friday’s explosion was the fifth terrorist attack in Britain this year. At least three of the attackers who struck Britain this year were previously known to law enforcement officials. Authorities have acknowledged that it is impossible to keep track of all suspects, and it is believed that British security services are constantly monitoring about 500 people. According to European Union officials, the number of Islamist extremists in the country could be up to 50 times that.

Lauren Hubbard, 24, had just stepped on the Tube at Parsons Green — the beginning of her morning commute to her job in the financial district — when she felt intense heat. Then she saw flames barreling toward her.

“I could see the fire,” she said. “I could feel the heat of it. At first you just panic, then you just run.”

Kate Llewellyn-Jones, 42, who lives next to the station, said she heard shouting and then a woman ran into her yard. She had lost her shoes in the stampede.

This thought struck many: Why attack here? Parsons Green is not a tourist magnet but a leafy enclave.

After the recent spate of attacks in London and Manchester, the British prime minister was criticized by the opposition for slashing local police staffs.

On Thursday, Britain’s Home Office announced that police, using broader authorities, had arrested a record 379 people for terrorism-related offenses in the past months, an increase of almost 70 percent.

Jennifer Hassan in London, Paul Schemm in Addis Ababa, Ethi­o­pia, and Brian Murphy and David Nakamura in Washington contributed to this report.