High interest rates caused a 39 percent decrease in the first-quarter earnings of Federal National Mortgage Association, and this quarter is expected to be worse.

Chairman Oakley Hunter told stockholders of the secondary mortgage market corporation at yesterday's annual meeting that he anticipates "sharply lower earnings" and "possibly a loss" during the next few months until Fannie Mae can refinance its $9 billion debt at lower interest rates. It would be Fannie Mae's first such loss in its 12 years as a private corporation, chartered by Congress.

Fannie Mae had first-quarter net income of $24.2 million, down from $37 million in the previous quarter and $39.5 million in the first quarter of 1979. Despite a decline in earnings per share from 65 to 40 cents, the 32-cent-a-share dividend was maintained.

At a time when traditional lenders had little money, Fannie Mae provided the bulk of mortgage funds in many areas by buying up their mortgages. Commitment fees -- to purchase mortgages at a given rate at a future date -- more than doubled over the previous year. Purchases of mortgages for the first four months of this year totaled $4.3 billion, comparable to last year's pace.

Hunter said Fannie Mae is making progress in new programs to buy renegotiable-rate mortgages, issue conventional mortgage-backed securities and buy home-improvement loans.

He further said only a "few small differences" remain with the Department of Housing and Urban Development before Fannie Mae can start on a program to purchase mortgages on mulifamily rental residences of five or more units. However, he added that impediments such as rent control might make such a program difficult.

Hunter estimated housing starts in 1980 at between 1 million and 1.2 million. Board member James J. O'Leary, who is chief economist of U.S. trust Co. in New York, predicted the recession would last "at least through the year and somewhat longer. Although it will not be as severe as that of 1974-75."

O'Leary said short-term interest rates will drop to between 6 percent and 7 percent (on 90-day Treasury bills), by year end, while the prime rate will go below 10 percent a lot sooner than that. He projected long-term interest rates (on government bonds) will be between 9 percent and 10 percent by year end. Mortgage rates will reflect them.

In answer to a question, Hunter said Fannie Mae's relations with HUD are "cordial and cooperative, and never as bad as they might have appeared." The reference was to his famous controversy with former HUD Secretary Patricia Harris, who tried to pack Fannie Mae's board with presidential appointees to undercut Hunter.

Appointed to the board yesterday were former Federal Home Loan Bank Board Chairman Robert McKinney, and Darralyn C. Bowers, a Detroit real estate broker who serves as chairman of the Black Caucus of the National Association of Realtors.