D.C. housing director Robert L. Moore told developers Oliver T. Carr and Theodore R. Hagans Jr. yesterday to agree before Tuesday to buy the Metro Center redevelopment site from the city at a price much higher than the two had offered to pay or face the threat of losing the choice downtown tract.

The ultimatum was in sharp contrast to the attitude of compromise and agreement that Moore and Carr showed each other 10 days ago at a meeting of the city's urban renewal agency when it appeared that an end to a long price stalemate over the property was in sight.

At that time, Carr told the five-member board, which includes Moore, that the two sides had agreed in concept to permit the developers to drop plans for a large hotel as part of the planned $211 million office and retail complex to be built on the north side of G Street between 11th and 13th streets.

In return, Carr and Hagans pledged to raise their original offer of $37 million closer to the $54 million the city wanted. The two sides indicated that they could reach an agreement within five days.

But the negotiations broke down, and yesterday, in the most strongly worded threat yet to progress on the project, Moore sent a letter to the developers stating that the city would accept no less than $50 million to $51 million for the 3.7-acre site. The letter ended with a declaration that "there will be no further negotiations on this matter," according to a source who had seen the letter.

Moore said the letter meant, "Mr. Carr has to accept or reject the city's price tag . There are no more negotiations. That time has run out. We are at the end of the process . . . Now is the time for the rubber to meet the road."

Louis P. Robbins, Carr's attorney, said the letter had been received and a response would be ready on Monday. The Redevelopment Land Agency meets the following day.

Nira Long, chairman of the agency, and other board members indicated last week that they were tired of having the negotiations drag on. Long was out of town yesterday and could not be reached for comment.

Two weeks earlier the board had threatened to take the project away from Carr and Hagans if an agreement could not be reached on a price. That threat was initially blunted by the apparent agreement reached March 1 and discussed the following day.

The dispute over Metro Center marks the first time that the city has been involved in a protracted quarrel with developers over the price of a piece of land.

In the last six months, the city agency's practice of selling downtown redevelopment sites at prices lower than some paid on the open market has been criticized--most recently in a report issued this week by the General Accounting Office.

Partly in response to such criticism, the agency has sought higher prices. In December 1980, for instance, it sold a choice parcel of real estate on the southwest corner of 12th and G streets NW for $130 a square foot; seven months later it sold another downtown tract at Seventh and G streets for $141 a square foot.

Both sales occurred at a time when the square-foot price for some privately owned land in downtown was $500 to $600.

The price the city originally asked Carr and Hagans to pay for the Metro Center site--$54 million or $335 a square foot--would be the highest price paid so far for city-owned land.

If RLA cancels its exclusive development rights agreement with Carr and Hagans, it is unclear how another developer would be selected.

Some housing officials have suggested that instead of readvertising the project, the agency should ask five other development teams that previously bid on the project if they were still interested and could meet the city's price.