Image copyright AP Image caption The two girls faced back-to-back competency hearings on Thursday

Both girls accused of stabbing a Wisconsin classmate in order to please an online fictional character are competent to stand trial, a judge says.

Judge Michael Bohren ruled Morgan Geyser, 12 and Anissa Weier, 13, mentally competent during a hearing.

Doctors retained by the defence previously deemed Ms Geyser not mentally competent.

They allegedly stabbed another girl 19 times in "dedication" to Slenderman, a fictional website character.

The victim, also 12 at the time, was reportedly found by a cyclist on 31 May after crawling from the woods where she was attacked with stab wounds to her arms, legs and torso.

His decision means both cases will continue to preliminary hearings, where a judge will decide whether there is enough evidence for trial.

Image copyright AP Image caption The unidentified victim thanked her well-wishers following the attack

She has recovered and since returned to school.

Both suspects were later found walking near a local highway, and a knife was found in one of the girls' backpacks, police said.

According to police, the girls planned to stab the classmate during a sleepover but instead decided to commit the crime the next morning in a nearby park.

Following their arrest they told investigators about their belief in paranormal figure Slenderman and their desire to become his "proxies" by killing to demonstrate their loyalty, police said.

After the murder, they reportedly intended to walk to Slenderman's mansion, which they believed was situated in Wisconsin's Nicolet National Forest.