A suicide bomb suspect has died in an operation by Canadian police to thwart what they said was a planned attack.
A senior police official said Aaron Driver allegedly planned to use a bomb to carry out a suicide mission in a public area.
The official said the suspect was Aaron Driver, originally from Winnipeg, Manitoba, and in his mid-20s. He was under a court order made earlier this year to not associate with any terrorist organisation, including the Islamic State of Iraq and the Levant.
In February, Driver's lawyer and the prosecutor agreed to a peace bond stating there were "reasonable grounds to fear that he may participate, contribute directly or indirectly in the activity of a terrorist group".
The police operation continued well into Wednesday night in the southern Ontario town of Strathroy, about 140 miles south west of Toronto.
Irene Lee said police had been camped out near her parents' convenience store since about 4.15pm local time.
She said she was at her home nearby when she heard a loud noise. She said shortly afterwards a police officer told residents to stay inside their homes.
Ms Lee said there were up to 25 marked and unmarked police vehicles outside a home on a street behind her parents' store.
The Royal Canadian Mounted Police said earlier it halted a possible attack after receiving credible information of a potential terrorist threat.
It said a suspect was identified and the "proper course of action has been taken" to ensure there was no danger to public safety.
Public safety minister Ralph Goodale said he had spoken to prime minister Justin Trudeau about the events "to confirm that public safety has been and continues to be properly protected".
"The RCMP, the Canadian Security Intelligence Service and other police and security agencies were involved in the operations," he said.
"These agencies conducted themselves effectively in the circumstances that developed today."
The national terrorism threat level for Canada remains at "medium" where it has stood since the fall of 2014, Mr Goodale said.
Winnipeg-based lawyer Leonard Tailleur, who handled Driver's peace bond, said he was "shocked" to hear what had happened.
"Saddened to hear that it had to end this way for him," Mr Tailleur said in an email to The Canadian Press.