Mayor Marion Barry's administration, after weeks of internal debate, has settled on a strategy to fend off possible legal challenges to its novel plan to shift $12 million in street lighting costs to District utility users.

A key element is to have the City Council adopt a resolution formally endorsing the plan and spelling out its legal justification. That move, administration officials say, would improve the plan's chances before the Public Service Commission and would blunt arguments that Barry is acting illegally.

Barry plans to ask the PSC to approve a rate increase for all of Pepco's District customers to cover the cost of street lighting that is now paid to the utility by the city.

The proposal, which Barry used to help balance the recently approved fiscal 1984 budget, has been denounced by officials of the Potomac Electric Power Company (Pepco), who have vowed to oppose the measure.

"There's a general agreement that some direction has to come from the City Council to the PSC in order to define the government's intent in the area," said Thomas Downs, director of transportation and public works and a key figure in the administration's deliberations.

Downs said the administration was inclined to seek a council resolution, which could be passed quickly, rather than legislation, which would require lengthy council consideration and congressional review.

Council Chairman David A. Clarke said yesterday he would support the resolution, but noted that such a measure would not legally compel the PSC to approve a rate increase. "I believe we are committed to carry through what we voted in the budget," Clarke said.

Alan G. Kirk, a Pepco senior vice president and general counsel, told a council committee during budget hearings in January that Barry's proposal was impractical, inequitable and illegal under District law. Yesterday, a Pepco spokeswoman said, "We have every intention to oppose this proposal."

Pauline Schneider, assistant city administrator for intergovernmental relations, said city lawyers are confident the proposal can withstand a legal challenge. "There is agreement on the legality of our position," she said.

In an interview yesterday, Barry declined to discuss details of his strategy or predict its success.

"Obviously if it develops that that program can't go forward, I have to either send a new revenue package over to the council to compensate for that or reduce the budget," Barry said, but added that, "I'm confident that we're going to be able to implement this program."

The street lighting proposal is included in the city's 1984 budget, which the mayor is required to act on by Monday. Unless he vetoes the budget, it will go to President Reagan for transmittal to Congress.

Barry said yesterday he hasn't decided yet whether to sign the budget because of several reservations about the council's actions--including a decision to increase revenue estimates by about $2.5 million.

Barry contends that the mayor has sole authority to project revenues and that the council acted illegally. "We have to protect the institutional processes," he said.

In another budget issue, Barry said that several agencies are having trouble staying under their congressionally mandated spending levels for the current year. He said he may soon ask Congress for authority to raise the spending ceilings for some of those agencies, while reducing spending elsewhere in the budget. However, he declined to name those agencies.