Virginia has agreed to pay $51,000 to settle a lawsuit alleging that state officials illegally wiretapped telephone calls on death row at the Mecklenburg Correctional Center.

Under terms of a proposed out-of-court settlement submitted Friday to U.S. District Judge Robert R. Merhige, the American Civil Liberties Union, which brought the lawsuit, has agreed that the state had a good-faith defense to a suit for damages because officials relied on a circuit court order allowing the wiretaps, Gerald T. Zerkin, the ACLU's lead lawyer in the case, said yesterday.

"But the court order was not valid . . . and the wiretap was illegal," Zerkin said.

The state conceded in its settlement that wiretapping occurred at Mecklenburg a year ago by prison officials relying in good faith on the court order. That good-faith finding means that all claims against the state and its employes are to be dismissed, according to the proposed settlement.

In exchange for the ACLU dropping its suit, the state's insurance company is to pay a token $500 per person for each of the 102 identifiable plaintiffs whose calls were intercepted on death row.

Lawyers for the ACLU sought at least $2.5 million in overall damages when they filed the lawsuit in early March.