HAMBURG, West Germany (AP) _ Soviet leader Mikhail S. Gorbachev has taken a keen personal interest in the case of 19-year-old West German pilot Mathias Rust and is regularly briefed on the investigation of his flight to Red Square, the Hamburg magazine Stern reported.

A Soviet newspaper meanwhile alleged Sunday that ''well-known circles in the West'' were responsible for planning Rust's flight and said it was an attempt to provoke the Soviet Union and scuttle Soviet arms control proposals.

The latest issue of Stern describes Rust's meeting with his parents, Karl- Heinz and Monika Rust, in Moscow's Lefortovo prison, where he is being held. It also reports on their talks with his KGB interrogators.

The article, published last week, said a KGB official indicated Gorbachev may meet with Rust, but did not elaborate.

The weekly bought exclusive rights to the story of Rust's parents soon after he landed in Moscow on May 28 in a small, single-engine Cessna 172.

Rust, of Wedel, West Germany, took off from Helsinki, Finland, flew unhindered through heavily guarded Soviet airspace and landed at Moscow's Red Square. He was arrested shortly after landing. Soviet officials refused to say if Rust will be tried for violating Soviet airspace.

Stern quotes Rust's parents as saying their son was being treated very well.

According to Monika Rust, one KGB official present during the visit with their son told her Gorbachev was ''regularly receving information'' in the case, Stern said.

The Soviet Foreign Ministry told the West German Embassy in Moscow that Gorbachev personally read a letter written to him by Rust's parents, it said.

Mrs. Rust said Mathias was ''working happily with his interrogators'' and described one KGB major as a friend, the magazine reported.

Asked by his parents if he was aware that several top Soviet military officials, including former Defense Minister Sergei Sokolov, lost their jobs as a result of his flight, Mathias Rust reportedly replied affirmatively.

Mr. and Mrs. Rust strongly denied that their son had help in preparing the flight, according to Stern. They said he made the flight because he wanted to do something for peace and believed Gorbachev was serious about disarmament.

An article in the Soviet youth newspaper Komsomolskaya Pravda, titled ''A Far-Reaching Subversive Act,'' implied on Sunday, however, that Western intelligence agencies wanted to provoke the Soviet military into shooting down Rust's plane, prompting a world outcry that would ruin chances for an arms control agreement.

The article, by lawyer A. Savinov, said Rust's flight had the same purpose as that of the Korean Air Lines jetliner shot down on Sept. 1, 1983.

Komsomolskaya Pravda repeated the Soviet claim that KAL Flight 007 was on a spying mission for the CIA and Pentagon when it strayed into Soviet airspace and was shot down in the Soviet Far East, killing all 269 people aboard. The incident drew world condemnation.

The paper said that incident impeded arms talks.

The Reagan administration has denied the Korean plane was on a spy mission.

In Rust's case, Komsomolskaya Pravda said it was clear the flight was premeditated.

''The time when all the i's will be dotted and all the t's crossed is not far away,'' the newspaper said. ''However, it is safe to assert even now that the Soviet Union's airspace was violated with a far-reaching aim.''