The man who tried to kill President Ronald Reagan in 1981 is set to be released from a mental institution 35 years after the assassination attempt. John Hinckley Jr. has been granted “full-time convalescent leave” from St. Elizabeths Hospital in Washington, D.C., beginning August 5, according to Fox News.

A federal judge granted the release on Wednesday, July 27. The ruling will allow Hinckley Jr. to live in Williamsburg, Virginia, with his mother. Experts who testified at the hearing all agreed that Hinckley’s depression and psychotic disorder are “in full and sustained remission and have been for more than 20 years,” Fox News reports.

The home of John Hinckley's mother in the Kingsmill resort in Williamsburg, where the would-be assassin is set to stay.Steve Helber/AP Photo

Hinckley, who is now 61, was 25 years old when he shot Reagan and three others outside the Washington Hilton in March 1981. Reagan was wounded when a bullet ricocheted off his presidential limo. One of the victims, White House press secretary James Brady, died in 2014 due to injuries from the assassination attempt.

Hinckley was arrested at the scene and later found not guilty by the defense of insanity. He allegedly tried to kill Reagan to get the attention of Jodie Foster, according to Fox News. He became obsessed her with after seeing the 1976 film Taxi Driver, in which a disturbed man plots to assassinate a presidential candidate, Fox News reports. As a result of the verdict, Congress has revised legislation about when the insanity defense can be used.

Police and Secret Service agents diving to protect President Ronald Reagan amid a panicked crowd during an assassination attempt by John Hinckley Jr. outside the Washington Hilton Hotel in Washington, D.C.Hulton Archive/Getty Images

The release has been a long time coming, as Hinckley has slowly gained more freedom over the years, according to Fox News. In 2003, Hinckley was first allowed to visit his parents’ home for the day. By 2006, he was able to leave the hospital for up to three days at a time, and in 2013, the court ordered that he could take up to 17-day visits to his parents. After his release, he will continue to attend individual and group therapy and cannot speak to the media.

Reagan’s daughter Patti Davis has previously opposed letting Hinckley spend more time outside the hospital. “I hope the doctors are right when they say that John Hinckley isn’t a danger to anyone but something in me feels they are wrong,” she wrote on her website last year.