President Reagan has known since September that his national security adviser, Richard V. Allen, is being investigated by the Justice Department for taking $1,000 from a Japanese journalist, White House communications director David Gergen said yesterday.

Gergen said last Friday that Reagan had been informed that morning by presidential counselor Edwin Meese III of the incident, but Gergen corrected himself yesterday.

"I subsequently learned that he knew of the fact that the matter had been referred to the Justice Department prior to that time . . .approximately at the time the money was discovered," Gergen said. He added that last Friday Meese had simply informed the president that the story had become public.

Gergen said that Reagan has confidence in Allen and that the president has not said to anyone that he is embarrassed by his national security adviser's decision to take an envelope containing cash and place it in an office safe. Allen says he forgot about the $1,000, which the journalist offered as a thank-you gift to Nancy Reagan for a brief interview.

Allen has not offered his resignation since the cash was discovered by an unidentified person in mid-September, Gergen said.

Gergen was asked whether The Washington Post report that one of the top three White House aides had notified the FBI without informing Allen meant that someone was out to get the national security adviser.

"No, you shouldn't read that into this," Gergen said while refusing to comment on the story that the FBI was brought into the case by one of Allen's superiors--Meese, chief of staff James A. Baker III or deputy chief of staff Michael K. Deaver.

Despite the discovery of the cash and Allen's explanation that he had intended to turn it over to the treasury and had not rejected it out of a desire not to embarrass the Japanese journalist, the president and his top aides decided the matter should be kept from the public.

Gergen was asked whether the White House would ever have decided to disclose the episode if it had not been leaked to a Japanese newspaper. He said that would have been a decision that the president and his advisers would have had to make "somewhere down the road."

Asked whether it would have been better for the White House to announce the investigation rather than have it leak to a newspaper in Japan, Gergen replied: "That's a judgment call."

He defended the way the incident has been handled. "Our description of what happened is that the proper procedures were followed," he said.

Allen struck a similar note. He told reporters he has no reason to believe that it was one of the White House "Big Three" who called in the FBI, "but, if that were so, wouldn't the American people be somewhat reassured that the system works and works well?"

Gergen said he did not know whether Reagan was informed of the cash in the safe before or after the FBI was notified. He said only that the two events happened at about the same time.

Beyond correcting the record about when the president learned of the incident, Gergen deflected other questions by citing the policy adopted Saturday of not commenting on the grounds that the matter is under investigation by the Justice Department. If the correction had not been made it would have appeared that Reagan's aides knew of the cash, informed the FBI and kept the news from the president until press leaks forced them to tell him.

Under the Ethics in Government Act, Justice has up to 90 days to determine whether to recommend that the attorney general appoint a special prosecutor to conduct a full-scale investigation.

Allen helped arrange an interview with Mrs. Reagan for the Japanese magazine Shufu no Tomo (Housewife's Companion) last Jan. 21. A long-time friend of Allen's acted as the interpreter for the magazine's writer during the brief interview, which probably was the first Mrs. Reagan gave after her husband took office.

When the Japanese offered a cash thank-you, Allen says he took it, gave it to a secretary with the intention of finding out how to turn it over to the government and then forgot about it for eight months.

"Mr. Allen wishes he had not forgotten the money," Gergen remarked.