The Justice Department filed suit in federal court here yesterday against the D.C. Fire Department's new affirmative action plan -- which calls for strict numerical goals to increase minority representation -- saying that it is "discriminatory because it grants preferences based on race and sex."

Justice has challenged what it views as "racial quotas" in court battles around the country, but the civil lawsuit against the District marks the first time Justice has initiated legal action, according to a spokesman.

The lawsuit claims that the fire department's affirmative action plan violates civil rights laws by establishing hiring procedures that give "preference to certain candidates because of their race, sex or national origin." It also attacks promotion procedures that, according to the suit, give preference "because of race."

The impact of the lawsuit filed at U.S. District Court could reach far beyond the District, according to both sides in the longstanding battle over the use of what civil rights advocates call "goals" and what opponents call "quotas" as a means of redressing employment discrimination.

The battle has become more intense since the Supreme Court ruled last June in a case involving a dispute between black and white Memphis firefighters over layoffs there. The high court ruled against the black firefighters, saying that courts cannot interfere with seniority systems to protect the jobs of newly hired black workers when layoffs are deemed necessary.

The ruling appeared to embrace the Reagan administration's central argument on civil rights: that federal antidiscrimination law bars the use of quotas and other such remedies for employment discrimination.

While some courts have taken a narrower view and upheld quotas, Justice has become involved in several court battles on that issue, using its broad interpretation of the Supreme Court ruling.

"This lawsuit is consistent with the administration's pattern of trying to roll back the calendar in terms of eliminating longstanding patterns of discrimination," said Ronald L. Ellis, a lawyer with the NAACP Legal Defense and Educational Fund in New York. "It is a sad day now that the Justice Department is bringing suits against attempts to break down those patterns of discrimination."

In announcing the filing, William Bradford Reynolds, chief of Justice's Civil Rights Division, said: "Racial quotas cause real injury to identifiable persons, and are just as inconsistent with federal law as outright exclusion because of race. This action should indicate that the federal government will proceed in court to protect the rights of any public employes who are disadvantaged because of their race."

Yesterday Thomas Tippett, president of Local 36 of the International Association of Fire Fighters, said the union was "ecstatic" about the lawsuit. He said the affirmative action plan and the promotion of five black firefighters last week were "just tearing this department up."

The D.C. plan that was the target of yesterday's action calls for strict numerical goals for hiring and promoting members of minorities and women in an effort to correct imbalances revealed in a study that found minorities and women underrepresented and underpaid at almost every level of the department.

To redress what the plan calls "gross disparity between minorities/women and white males" in the department, it sets strict percentages for the hiring of minorities and women and calls for specific numbers of minorities to be promoted to the ranks of sergeant, lieutenant and captain.

Mayor Marion Barry defended the plan yesterday as just and equitable. "We have worked hard to create a plan and an atmosphere where everyone has an equal opportunity to move forward in the District's fire department," he said in a statement.

Shortly after the plan was disclosed in late February, Rep. Stan Parris (R-Va.) wrote a letter to Justice, condemning the plan as "inequitable" and urging the department "to determine whether it is consistent with the recent court rulings" on employment discrimination.

Parris said a number of his constituents who are D.C. firefighters had called him "to protest the fairness of the plan."

Yesterday, Reynolds said the lawsuit was based on complaints from fire department members.

The plan was the product of an agreement worked out by U.S. District Court Judge Charles R. Richey in a case initiated by black firefighters. The plan was approved by the D.C. Office of Human Rights in January but has been the subject of legal attacks ever since.

Local 36 immediately filed court papers with Richey opposing the plan as biased against whites. Last Friday, the union initiated a separate lawsuit challenging the promotion provisions of the plan as discriminatory. A few hours later, the department promoted five black firefighters to sergeant -- an action based on the plan's provisions, according to the union.

The parties in those lawsuits were scheduled to meet for a conference today with Richey, and now Justice is scheduled to join that session. The department is seeking an injunction "prohibiting the city from using race- or sex-based preferences in hiring and promotion," Reynolds said.

At a news conference yesterday, union president Tippett said, "Our white members are upset at the prospect of being denied a promotion strictly because of their race," he said. "The black members are equally upset about a stigma being attached to their promotions. They studied hard and many of them did well in the 1984 promotion exam.