The Justice Department today warned the nation's 200 regional health planning agencies that some of their methods of planning and allocating hospital beds and other medical services could violate federal antitrust laws.

The caution came in a letter to the Central Virginia Health Systems Agency here, but Justice Department officials said the warning had national implications. "This is a detailed statement of enforcement that applies not only to Virginia, but nationwide," said Mark Sheehan, a Justice spokesman.

In the letter the department's antitrust division warned that the Richmond medical agency's program could be illegal if it leads to agreements among competing hospitals that limit the number of beds or the kinds of services they offer.

The department's warning is the latest development in an ongoing debate over the reasons for soaring hospitals costs. Some experts argue that lack of national health-care planning has led to duplication of expensive services and pushed up costs. Others say more free market-style competition between institutions would ultimately help keep costs down.

The letter was immediately criticized by regional and national spokesmen for the planning agencies, which were ordered established by Congress in 1974 to help communities develop quality medical services and restrain costs by avoiding duplication. In Virginia, the agencies have advised the state health commissioner on the need for services ranging from x-ray machines to the nation's first test-tube baby clinic in Norfolk.

"This could be a very serious development and, in my view, it would run directly contrary to what the Congress intended when it passed and later amended the Health Planning Act," said Harry Cain, executive director of the Washington-based American Health Planning Association. The group claims most of the regional agencies as members.

"Part of any rational allocation of [medical] resources involves cooperative efforts, particularly among institutional providers such as hospitals," said Cain. "If the Justice Department is going to suggest that a kind of working together violates antitrust laws, it would be a nonsensical pronouncement."

Federal and state antitrust laws generally allow exemptions for cooperative business efforts approved by acts of Congress or of state legislatures. But the Justice letter cautioned that because the health-planning agencies are publicly financed, nonprofit corporations rather than government agencies, some of their activities may not qualify for the exemptions.

According to Roland Pitts, assistant director of the central Virginia agency, the group developed a 400-to-500 page research health plan in 1978. Under the plan, the Richmond agency, which is a publicly financed, non-profit corporation with a 30-member board of directors, would review existing and projected medical services of hospitals and other health institutions. It would then recommend to state and federal health agencies whether new services should be approved.

Pitts said the plan ran into opposition from a local hospital group, which argued that the plan could inhibit competition and new services at the hospitals. When the group raised antitrust questions in January 1979, about the plan, the agency decided to seek a Justice Department review.

In a letter to the agency from Sanford M. Litvack, assistant attorney general in the antitrust division, the Justice Department gave its approval to the agency's plan to review services and make recommendations. But it questioned the agency's statement that it would seek "the assistance of individuals and public and private entities" in implementing the plan.

The Justice letter specifically questioned the plan's stated purpose of encouraging "cooperative assessments" among hospitals offering delivery room services in the area. The plan called for "joint action to adjust the number of beds, physicians and allied health manpower . . . in a manner that will best serve the needs of the people."

Litvack warned that such "joint actions" might be illegal, although neither he nor a department spokesman reached today offered a definitive ruling.

The warning could have widespread implications because duplication of obstetric services, which results in empty delivery room beds, is considered a common problem in many parts of the country.

Pitts said that consulation with hospitals was an essential part of the planning process for the agencies.

"If you sit here in a vacuum and make judgments on planning without talking to the key people involved, it will never work," said Pitts. "If they're saying we can't meet with these people, they'll be severely inhibiting us from doing our jobs."