President Reagan plans to increase greatly the power of his national security affairs adviser and is expected to move Deputy Secretary of State William P. Clark into that job as replacement for Richard V. Allen.

This shift, which would put Clark at the top levels of White House decision-making, still is technically dependent on a decision by Reagan about whether to retain Allen, who is on administrative leave. He was cleared last week by the Justice Department of allegations of illegalities in his past business dealings, but is still awaiting a final White House review of the propriety of his conduct.

However, senior White House sources said yesterday that now that Reagan has decided to upgrade the national security adviser's post, it is very unlikely that Allen will be retained.

Clark, an old friend and political associate of Reagan, was in Palm Springs, Calif., with the president yesterday and could not be reached for comment. According to the sources, though, a decision on the change could be made by the time the president returns here Sunday and is likely to be announced early next week.

The sources said the move was motivated not only by the notoriety surrounding Allen's legal difficulties but also by a consensus in the White House top echelon that the national security apparatus had not worked effectively during the first year of Reagan's presidency. Allen, who reported to Reagan through White House counselor Edwin Meese III, was far more circumscribed in his authority than previous occupants of his post.

Meese, who earlier had originally resisted suggestions that the national security position be elevated, recommended the upgrading of the adviser's job in a conversation with the president this past week, according to a senior White House official, and Reagan is said to have agreed. The president was also said to have agreed with Meese's recommendation that, if Allen is to be replaced, his successor should be Clark.

White House chief of staff James A. Baker III and deputy chief Michael K. Deaver, who with Meese run the White House staff, reportedly had come to the same conclusions.

Meese made his recommendation to the president after conducting a study of the National Security Council staff's operations.

The official said Meese concluded that national security policy-making had been plagued by "confusion" and lack of coordination because there was "no single focal point" in the White House for contact with top officials of the State Department, the Defense Department and the Central Intelligence Agency.

"The person who is the national security adviser must have direct access to the president," said the senior official. "And just as important, he must have the perception of direct access in the eyes of State, Defense and the CIA."

This position represents an about-face from the administration's original publicly stated desire to avoid the concentration of power in the national security adviser's job by subordinating him to Meese.

In previous administrations, this concentration of power had caused frequent embarrassing conflicts between such occupants of the job as Henry A. Kissinger and Zbigniew Brzezinski and Cabinet officials.

Under the new system, the national security adviser will have "direct day-to-day operational responsibility," according to the senior presidential official. He will meet daily with the president, and will deal directly with Secretary of State Alexander M. Haig Jr., Defense Secretary Caspar W. Weinberger and CIA Director William J. Casey.

Although Meese will retain overall responsibility for policy coordination, the practical effect of the new division of responsibilities will put the national security adviser more or less on a par with the White House's controlling staff triumvirate of Meese, Baker and Deaver.

Meese is known to have maintained within the White House staff that he never wanted to supervise day-to-day national security coordination but was forced into that role because "personality conflicts" developed from the outset between various officials, notably Haig and Allen.

"It got to the point where we had Al Haig talking with Jim Baker or Mike Deaver or Ed Meese, but there was no single focal point at the White House," the senior official noted.

The hope of improved future coordination apparently was a major factor in turning to Clark.

Although the former California Supreme Court justice had no experience in foreign policy when he came to Washington, he has carved out an important niche during his months at the State Department through his ability to mediate effectively between the often mercurial Haig and the White House.

Clark, 50, did this by winning Haig's trust and confidence, while retaining his credentials as a member in good standing of the group that has been Reagan's political inner circle since his days as governor of California.

In fact, it was Clark, while serving as Reagan's first chief of staff in Sacramento, who recruited Meese and Deaver for the governor's team, and he also is a long-time close friend of Weinberger.

Over the past year, these attributes have gone a long way toward overcoming the embarrassing lack of expertise in international affairs that Clark displayed during his Senate confirmation hearings last February. At the White House, his ability to get along with Haig was regarded as so important that many administration officials assumed Reagan would be reluctant to take him away from State.

Since there still are a lot of gaps in his knowledge of foreign policy issues, some officials are known to believe it will be a mistake to put him in a job whose main functions involve keeping the president and his top national security aides up to date on the analysis and implications of international events.

However, the president's top advisers believe Clark will be able to expand the mediating role he played at State into an even wider sphere from the White House.