Presidential assailant John W. Hinckley Jr., comparing his confinement at St. Elizabeths Hospital to the exile of Soviet dissident Andrei Sakharov, described himself this week as a "political prisoner" the government wants "silenced and locked away permanently."

Hinckley's statements were contained in a five-paragraph, handwritten letter addressed to The Washington Post and received on Tuesday. The letter comes two weeks after hospital officials said they had relaxed restrictions on mail sent and received by Hinckley "in view of improvement in his clinical condition and judgment."

Hinckley has been confined at St. Elizabeths here since June 1982 after being found innocent by reason of insanity by a jury in the 1981 shooting of President Reagan.

"I am a political dissident and the government wants me silenced and locked away permanently," Hinckley, 29, said. "I refuse to let this happen. There is no difference between John Hinckley and Andrei Sakharov."

A St. Elizabeths spokesman declined to comment yesterday on the contents of the letter, but confirmed that Hinckley was its author. The spokesman said Hinckley voluntarily showed the letter to his psychiatrist, Dr. Joan A. Turkus, before mailing it.

"It's his letter and we want to stay out of it," said the spokesman, Dr. Harold Thomas. "You have to take it any way you want to take it." Thomas said the hospital allowed Hinckley to send the letter "since it doesn't contain any threats. That doesn't mean we endorse it."

In the letter, Hinckley said he is being held in a "government hospital with government doctors. One of my vicitims is head of the government and so when it comes to me, the orders come directly from the White House."

He said he had asked District election officials twice to permit him to register to vote in next month's presidential election, but was rebuffed both times, most recently on Oct. 5. District law prohibits persons judged to be mentally ill from voting.

The second rejection by the District, Hinckley said, left him "no time" to register for an absentee ballot in Colorado, where he once lived with his parents near Denver.

The deadline for voter registration in Colorado was Oct. 6, Jefferson County Clerk Norman Allen said yesterday. Allen confirmed that Hinckley had not met the deadline and is not registered there.

"In the past two years," Hinckley wrote, "I have become much more politically aware and I can now see what's going on in this country. But I can't speak out or vote to try and change the system because the hospital and government won't let me.

"America does have political prisoners and I am one of them."

In an Oct. 4 hearing, U.S. District Court Judge Barrington D. Parker denied Hinckley's request for more freedom, including unscreened telephone calls, grounds privileges and more access to the media. Federal prosecutors opposed the request.

Turkus testified at the hearing that she and other doctors wanted to gauge how Hinckley handles his new mail privileges for three months before granting more freedom.

According to papers filed with the court by Turkus, Hinckley is now permitted to use the telephone on request to call his family, lawyers and others, once the purpose of the calls is screened by hospital staff members. Any attempt to contact reporters by phone is blocked.

"This is implemented by having his calls dialed by hospital staff," Turkus said.