Riggs National Corp. yesterday wrote off $27.2 million of the $133 million in loans it has outstanding to developing nations, becoming the second U.S. bank to formally admit it does not expect to recover a major chunk of the money it has lent to Latin America and other parts of the Third World.

Riggs, the largest bank company in the District, said it also will boost reserves against future losses on Third World debt by $21.3 million. Boosting the reserves will reduce the company's earnings by $14 million, or 96 cents a share, in the three months ending Dec. 31, and will result in a loss for the quarter, a Riggs spokesman said.

Because of the quarterly loss, the bank's expects its 1987 profits to be "slight," and certainly a "significant drop" from the $35.6 million it earned in 1986, Riggs spokesman David Palombi said. Riggs' price on the over-the-counter market fell 50 cents to $18.25 yesterday.

On Monday, the Bank of Boston surprised the banking community by announcing it would charge off $200 million of its $1 billion exposure to the Third World. The decision was expected to put pressure on banks around the country to follow suit. Many banks, however, will find that they can write off worthless loans only at the risk of pushing their capital below the amount required by federal banking regulators.

Federal officials and banking executives also said they fear writeoffs will signal to debtor nations that they needn't repay their loans.

Joe L. Allbritton, Riggs chairman and chief executive officer, called the step "a prudent action that is consistent with Riggs' demand for high asset quality."

Riggs said the company's action "will not deter Riggs in its efforts to collect all problem country loans and to reduce its exposure through other possible means."

The statement did not elaborate and the company spokesman would not specify the countries involved in the chargeoff or the reserve increase. "Because we're still going to try to collect from them," Palombi said, "we don't want them to know who they are." The bank did say that no loans to Mexico were written off "because of economic progress being made in that country."

A bank increases its loan loss reserve and deducts the same amount from profits when a loan is in serious trouble but not yet worthless. The bank is allowed to count the reserve as part of its capital -- the difference between assets and liabilities and, in theory, a cushion against possible losses.

When a bank decides a loan stands little if any chance of being repaid, it deducts the amount from the reserve, and in the process reduces the bank's capital cushion.

Riggs' writeoff reduces its capital to $600 million and cuts its capital ratio -- net worth as a percentage of total assets -- to 8.9 percent, down from 9.7 percent. The ratio still remains well above the 6 percent required by federal regulators.