The Supreme Court, saying drug use and violence in public schools are "major social problems," yesterday gave school officials broad power to search students suspected of carrying weapons, dealing drugs or even violating school rules.

Justice Byron R. White wrote for the majority in the 6-to-3 decision that constitutional restrictions generally applicable to police searches of suspects in criminal cases -- such as the need for a warrant or clear probable cause -- do not apply in schools.

Under the ruling, students still may not be subjected to unreasonable searches.

"The legality of a search of a student should depend simply on the reasonableness" of the search, given the circumstances of each case, White wrote. The majority upheld the search of a 14-year-old New Jersey student's purse after she was caught smoking a cigarette in a school lavatory.

The majority said that, to search students, officials need only "reasonable grounds for suspecting . . . that the student has violated or is violating either the law or the rules of the school."

Justices William J. Brennan Jr., Thurgood Marshall and John Paul Stevens dissented, saying the majority was giving school officials too much power under such standards. The case is New Jersey v. T.L.O.

The ruling came on an issue that has long divided federal and state courts trying to balance students' privacy rights and the need to maintain order in schools.

Some state courts have declared that school officials act with the authority of parents and that the Fourth Amendment's restriction on searches does not apply. On the other hand, at least one state court has ruled that the Fourth Amendment applies in full and that, in order to search students, school officials must have probable cause to believe that a crime or rules infraction has been committed.

The Reagan administration, saying in a brief that "disorder in the public schools is a national problem," had urged the court not to hamstring school officials.

The ruling, which generally accepted administration suggestions, adopts a middle ground accepted by most courts.

Solicitor General Rex E. Lee hailed the ruling as a "decision that should facilitate the maintenance of order and discipline within the schools while still maintaining the proper sensitivity to the interests of schoolchildren."

While reaffirming school officials' power, the court unanimously rejected New Jersey's position that students have no rights to be free from searches.

"Although this court may take notice of the difficulty of maintaining discipline in the public schools today, the situation is not so dire that students . . . may claim no legitimate expectations of privacy," White said. "We are not yet ready to hold that the schools and the prisons need be equated for purposes of the Fourth Amendment."

The court also did not accept New Jersey's argument that the exclusionary rule, which bars illegally seized evidence from being used at trial, should not apply in a school setting. Civil libertarians, who expressed concern that the court would agree with New Jersey's suggestions, were relieved.

The court "went too far," according to American Civil Liberties Union attorney Charles S. Sims, and gave school officials "more than they needed" to maintain order. But "there is language in the opinion that is very good" on students' rights to be "free from intrusive searches," he added.

The case began in March 1980 when a teacher at Piscataway High School in Middlesex County saw two girls smoking cigarettes in a bathroom. The teacher took the girls to the principal's office where they were questioned by assistant vice principal Theodore Choplick.

One girl admitted smoking in the bathroom, a violation of a rule. The other girl, 14, a freshman identified only by the initials T.L.O., said she did not smoke at all.

Choplick demanded to see her purse, where he found a pack of cigarettes, a packet of rolling papers, a small amount of marijuana, a pipe, some empty plastic bags, $40 in cash, a card that appeared to be a list of students who owed the girl money and two letters indicating that she was dealing marijuana.

Choplick called her mother and police. The girl admitted selling marijuana. She was tried as a juvenile, found delinquent and sentenced to one year on probation.

The New Jersey Supreme Court overturned that decision, saying her right against unconstitutional searches had been violated because Choplick searched the purse merely on a "good hunch."

The Supreme Court disagreed, saying the search was reasonable based on the facts of the case.

"The school setting . . . requires some modification of the level of suspicion of illicit activity needed to justify a search," White said. The usual "probable cause" standard is unnecessary, he said, and searches will be permitted when "the measures adopted are reasonably related to the objectives of the search and not excessively intrusive in light of the age and sex of the student and the nature of the infraction."

Brennan attacked the majority's "reasonableness" standard as "unclear, unprecedented and unnecessary." Joined by Marshall, he agreed that school officials do not need warrants to search students but said the "balancing test" advocated by the majority "portends a dangerous weakening of the purpose of the Fourth Amendment to protect the privacy and security of our citizens."

Brennan called the test a "conceptual free-for-all" and predicted that school officials "would be hopeless adrift" trying to use the majority's standard to gauge when a search is permissible.