One of two Wisconsin girls who attempted to kill a classmate in 2014 in an effort to please the fictional horror character “Slender Man" has been sentenced.

Anissa Weier, 16, was sentenced Thursday to 25 years in a mental health facility — the maximum punishment possible.

She pleaded guilty in August to being a party to attempted second-degree intentional homicide, but claimed she wasn't responsible for her actions because she was mentally ill. A jury agreed with her a month later.

Waukesha County Circuit Judge Michael Bohren sentenced Weier to 25 years in a psychiatric institution, retroactive to the date of the crime — meaning she would be institutionalized until age 37.

Weier, along with Morgan Geyser, lured classmate Payton Leutner into a wooded park in Waukesha in 2014. Geyser stabbed Leutner 19 times while Weier encouraged her, investigators said.

Leutner crawled out of the woods and a bicyclist found her. All three girls were 12 years old at the time of the attack.

SLENDER MAN STABBING VICTIM SLEPT WITH SCISSORS UNDER HER PILLOW, MOTHER SAYS

Leutner's mother sent the judge a letter this week detailing that the 2014 attack "has defined our lives," and that Leutner still fears for her life.

"She will struggle with the events of that day and physical and emotional scars it left for the rest of her life," Leutner's mother wrote.

Both Weier and Geyser told authorities they felt they had to kill Leutner to become Slender Man's "proxies," or servants, and protect their families from him.

Weier apologized before her sentencing, telling the court: "I do hold myself accountable for this and that I will do whatever I have to do to make sure I don't get any sort of delusion or whatever again."

"I want everybody involved to know I deeply regret everything that happened that day. I know that nothing I say is going to make this right and nothing I say is going to fix what I broke," Weier said.

Weier's attorney argued her client shouldn't be hospitalized past her 25th birthday. She played a video in court in which her father claimed Weier has "grown mentally and physically" and added that "she knows what she did was wrong."

Geyser, the girl who did the stabbing, pleaded guilty to attempted first-degree intentional homicide with the agreement that she isn't criminally responsible and shouldn't go to prison. She will be sentenced in February, and prosecutors have asked that she be given at least 40 years in a mental hospital.

"Slender Man" started with an online post in 2009, as a mysterious specter whose image people edit into everyday scenes of children at play. He is typically depicted as a spidery figure in a black suit with a featureless white face. He was regarded by his devotees as alternately a sinister force and an avenging angel.

The Associated Press contributed to this report.