Prosecutors agreed to drop the possibility of the death penalty, and Lane likely will be sentenced to life in prison. Sentencing was set for March 19.
Dressed in a green open-collared shirt with close-cropped hair, Lane answered "yes" or "yes, your honor" to questions from the judge about the plea agreement.
Prosecutors say Lane fired 10 shots at students in a cafeteria at Chardon High School, east of Cleveland. He was there waiting for a bus to another school.
Lane, who was 17 at the time of the shooting, was prosecuted as an adult. His appearance in a Geauga County courtroom came one day before the anniversary of the deadly shootings.
Both the defense and the prosecution had sought court-ordered psychiatric testing for Lane to determine if he would be competent to stand trial.
Before the case went to adult court last year, a juvenile court judge ruled that Lane was mentally competent despite evidence he suffers from hallucinations, psychosis and fantasies. He withdrew his plea of not guilty by reason of insanity on Tuesday.
Investigators say he admitted shooting at students but said he didn't know why he did it. Prosecutors say Lane took a .22-caliber pistol and a knife to the school on Feb. 27, 2012, and fired 10 shots at a group of students in the cafeteria.
Lane attended an alternative school for students who haven't done well in traditional schools. He was at Chardon waiting for a bus.