WASHINGTON — The Supreme Court on Monday threw out an enormous employment discrimination class-action suit against Wal-Mart that had sought billions of dollars on behalf of as many as 1.5 million female workers.

The suit claimed that Wal-Mart’s policies and practices had led to countless discriminatory decisions over pay and promotions.

The court divided 5 to 4 along ideological lines on the basic question in the case — whether the suit satisfied a requirement of the class-action rules that “there are questions of law or fact common to the class” of female employees. The court’s five more conservative justices said no, shutting down the suit and limiting the ability of other plaintiffs to band together in large class actions.

The court was unanimous, however, in saying that the plaintiffs’ lawyers had improperly sued under a part of the class-action rules that was not primarily concerned with monetary claims.