The attorney for Daniel Lang, Johnny Gaskins, said in court that his client has terminal prostate cancer and would not have been able to stand trial.
In exchange for his plea, the state will not seek the death penalty against Lang.
Lang was charged with first-degree murder in connection with the death of his wife, Shirley Lang, whose body was found on the grounds of Dorothea Dix Hospital, where she worked as a nurse. Authorities said she had been kidnapped and sexually assaulted.
During an autopsy, investigators found a note in the victim's pocket signed by her, saying Lang and another man were trying to kill her.
Prosecutors believe Daniel Lang did not want to lose his job for having sex with a patient, so they said he murdered his wife to keep his bosses from finding out. In June 2004, Daniel Lang pleaded guilty to sex charges related to that case.