The Rev. David H. Eaton, senior minister of All Souls' Unitarian Church who has been mentioned prominently as a possible candidate for D.C. mayor or City Council chairman, announced yesterday he would not run for either post.

Eaton, 45, made his decision known at the 11 a.m. service at the church at 16th and Harvard streets NW, where he has been minister since September 1969.

In an interview he said he reached his decision, which he described as a "rough one," on the basis of a feeling that his ministry to the church and city as a clergyman "was not in a position to be shifted (to electoral politics) at this time."

A secondary reason for the decision not to enter the mayoral race in particular, Eaton said, was that his candidacy in the September primary would "probably have given the incumbent (Mayor Walter E. Washington) an edge."

Two proven vote-getters, City Council Chairman Sterling Tucker and at-large Council member Marion S. Barry Jr., both have declared their intention to run for the mayoral nomination.

Mayor Washington has not made known his intentions, but has given indications that he may seek reelection.

"It will be a better race if the options are minimized," Eaton said, asserting that he hoped to give a better chance "to those hoping to give (the city) a different type of leadership (from that offered by the mayor)."

Informed sources have said in the past that both Tucker and Barry have asked Eaton to consider being the number two person - the council chairman candidate - on their respective tickets.

It was believed that Eaton, a forceful speaker with an activist background, could have furnished strong opposition to the Rev. Douglas E. Moore, a council member with a similar background who is widely seen as the leading contender for the chairmanship.

Neither Moore, Barry nor Tucker could be reached last night for comment.

Asked last night about the possibility that he might support Barry or Tucker in the mayoralty primary, Eaton said he would talk to both, watch them closely, and weigh carefully the positions they take before he makes a decision.

In explaining his decision not to run this year. Eaton said that All Souls' Church means so much to the community in general and to the city in particular that I feel I'd be neglecting my responsibility if I got into electoral politics at this time."

The 980 people who make up the congregation's membership span a broad economic, cultural and ethnic spectrum, including both wealthy people and welfare mothers, and natives of dozens of world nations.

Eaton had told the congregation last June that groups were seeking to draft him for the mayoral or council chairman races. When he announced yesterday that he would not run, his words were greeted with applause.

He said the church has just finished a successfual year, with a budget surplus. One reason his decision was announced yesterday, he said, is that yesterday was the start of a new fund drive.

While he would not seek office this year, he said in the interview, "I don't mean I won't consider elective politics as an instrument of the ministry sometime in the future."

Eaton is a former member of the city's Democratic State Committee, elected in 1976 on a slate headed by Tucker, Barry and D.C. Del. Walter E. Fauntroy.

The slate won an overwhelming victory in races against a slate supported by Mayor Washington. Eaton said he left the committee to concentrate on his work as a member of the city's law review commission, but said he may seek membership again.