The heavy consumption of sleeping pills by Americans is on the whole medically unjustified and possibly dangerous, a National Academy of Sciences study group charged yesterday.

In one of the most severe indictments yet of the pills, currently taken by 8.5 million persons a year, the group said they should not be the primary treatment for most patients with persistent insomnia.

The study group, a committee of the academy's Institue of Medicine, said the pills can often be useful. But it called on doctors to tell patients more about their dangers, to limit prescriptions mainly to "very limited numbers of pills for use for a few nights at a time," and to prescribe the drugs only rarely for regular use for more than two to four weeks.

The committee said drug ads in medical journals extolling sleeping pill benefits are often incomplete. For example, it said, said, ads for today's most widely used sleeping medicine-flurazepam or Dalmane, made by Hoffman-La Roche-fail to tell doctors of this drug's dangers.

Doctors are prescribing the pills far less than they once did. In 1971 they wrote 41.7 million prescriptions; in 1977, 25.6 million, though they wrote several million more for tranquilizers, antidepressants and antihistamines, which some patients use to seek sleep.

Nonetheless, the committe said, "it is difficult to justify" most current use.

In recent years the sleeping pills once most often used, the barbiturates, have been passed in popularity by the generally safer benzodiazepines, which include Dalmane, as well as the tranquilizers Valium and Librium, Fifty-three percent of all 1977 sleeping pill prescriptions were for Dalmane.

Only in the past year did the Food and Drug Administration require Hoffman-La Roche to tell doctors that Dalmane breaks down in the blood-stream to produce one product that can stay there for days.

Even the company's new labeling fails to say that this lingering compound's level on the eighth morning after a week of consecutive use is likely to proportionately greater potential for making the user too drugged to drive or operate machinery safely.

A hoffman-La Roche spokeswoman said yesterday the firm gives doctors all the facts "necessary and relevant" to prescribe the drug safely and effectively.

The committee said a sleeping pill's beneficial effect, if any, "is typically to reduce the time needed to fall asleep by 10 to 20 minutes and to lengthen the night's total sleep time by 20 to 40 minutes."

In general, the committee sad:

The FDA should make pill-makers give doctors more facts.

Doctors should get better training in treating the unsleepy.

Doctors should tell patients how all the drugs can interact with alcohol, sometimes for days after the pills are taken, to cause treacherous drowsiness and even death as the pills and alcohol reinforce each other.