District officials, under pressure from the National Capital Planning Commission, last week agreed to assure the preservation of one of the city's oldest buildings, Fire Engine Co. No. 5 in Georgetown, before selling it.

In addition, they agreed to an archeological dig on the reputed site of a historic tavern in Georgetown.

The action cleared the way for federal approval of the sale of 27 surplus city-owned properties the District hopes to sell to private developers for about $15 million.

The commission, which must approve the sale of publicly owned property here, had insisted on the stipulations before the two historic properties could be sold. District officials initially objected.

The planning agency wanted assurances that the 1797 firehouse at 3212 M St., which once served as town hall, the mayor's office and a hotel, would not be demolished. Under the city's historic preservation law it could be torn down if it were deemed to be "unsafe." Until last week city officials had not declared the building officially "safe," and its preservation was in doubt because of its poor condition.

The second dispute was over a portion of the Georgetown incinerator site at 31st and Water streets NW, thought to be the location of Suter's Tavern, where George Washington signed the agreement establishing the nation's capital.

Federal officials wanted guarantees that an archeological dig would explore the tavern site before bulldozers tore it up for development. District officials had objected that a dig would be expensive.

Alfredo Echeverria, city director of planning and the mayor's representative on the commission, announced last week that the city had dropped its objections to the archeological dig and that fire inspectors have found the old fire house to be "sound . . . not unsafe." It must therefore be preserved by any buyer.