A man accused of stabbing soldiers at a Toronto military recruitment centre in March has been found fit to stand trial.

Ayanle Hassan Ali, a 27-year-old born in Montreal, allegedly stabbed several soldiers inside the recruitment centre, sending two to hospital. Nobody was killed in the attack.

In May, he was found unfit to stand trial just hours after the RCMP laid terrorism charges in the case. That ruling was handed down following a two-month psychiatric assessment.

Judge Riun Shandler of the Ontario Court of Justice ordered Ali to undergo 60 days of treatment in a bid to improve his condition and leave him able to stand trial.

On Friday, in a Toronto courtroom, Ali was declared fit based on another psychiatric evaluation.

Ali, wearing a loose dark grey t-shirt, hung his head throughout the proceedings and did not speak. A pre-trial hearing is scheduled for Sept. 8.

He's facing a raft of charges.

The RCMP charged him with three counts of attempted murder, two counts of assault causing bodily harm, three counts of assault using a weapon and one count of carrying a weapon dangerous to the public, all for the benefit of a terrorist organization.

Similar charges were laid by Toronto police in March.

The attack at the recruitment centre in north Toronto took place on the afternoon of March 14 when Ali allegedly walked in brandishing a knife. In the days after the incident, Toronto Police Chief Mark Saunders said a man promptly began attacking a uniformed master corporal.

As military personnel moved civilians to safety, investigators said the man tried and failed to slash a female soldier before other soldiers were able to subdue him and hold him for police. Another military member was injured as the suspect was apprehended.

Court documents identified the victims of the attack as Ryan Kong, Jesus Castillo and Tracy Ann Gerhardt. None of their injuries were serious.

"While at the scene, the accused stated that 'Allah told me to do this; Allah told me to come here and kill people,"' Saunders said.

Little is known about Ali apart from the fact that he was born in Montreal and has lived in Toronto since roughly 2011.