The Internal Revenue Service is considering granting tax relief to thousands of depositors whose money is frozen in Maryland savings and loans, IRS and Maryland banking officials said yesterday.

If the IRS does not make a special exception, those depositors will have to pay income tax on interest their deposits earned last year, even though the funds could not be withdrawn.

The debate over the exemption probably will make it more difficult for depositors to file their state and federal income-tax returns early this year, no matter what the IRS decides. The four S&Ls with deposits still frozen have not yet sent out forms to taxpayers telling them how much interest their accounts have earned. Those "1099" forms are needed to complete individual income-tax returns.

IRS officials met yesterday to discuss ways of exempting the approximately 100,000 depositors whose money is still tied up in Old Court Savings and Loan of Baltimore, which is in receivership, and First Maryland Savings and Loan of Silver Spring, Community Savings and Loan of Bethesda, and Ridgeway Savings and Loan of Catonsville, which are under state control.

If the IRS decides not to tax the interest this year, the delay in sending the forms -- which under the law must be mailed by Jan. 31 -- will be even longer. It will take time to recalculate interest income to reflect only interest earned before the deposits were frozen in the spring and summer of 1985.

The IRS has been asked to give the S&Ls a 30-day extension of the deadline to mail the forms, and is expected to decide on the exemption in the next week or so.

"It's a matter of seeing whether they will be lenient to people who are locked up in a situation not of their own making," said Leonard Levy of the Maryland Savings and Loan Depositors Committee.

Last month, the IRS tentatively agreed to exempt interest earned on the Maryland accounts after the accounts were frozen for the 1985 tax year it will have to be taxed eventually in any circumstance . But after technical questions arose, the announcement of the decision was withdrawn and the issue went back to the drawing board.

"There is a lot of empathy for the depositors. But we can't base a decision on feelings, we have to base it on case law," said Dom LaPonzina, spokesman for the IRS in Baltimore.

The confusion also affects filing of Maryland state income tax returns. Because Maryland, like many other states, patterns its tax system after the federal code, state officials said they will adopt the IRS decision on taxation of interest.

"It's a very critical question at this point in time," said George H. Spriggs Jr., director of the income-tax division of the Maryland controller's office. "Taxpayers want to file their returns and can't file them until they have this information."

Worried Maryland depositors have made numerous calls to the offices of members of the Maryland congressional delegation, and legislators have asked the IRS to exempt interest on the deposits.

"It's an additional outlay," said Levy of the depositors' committee. "Many of these people are up against it."

In addition to interest on deposits in the four S&Ls where funds are frozen, the IRS ruling could also affect accounts in other S&Ls which are subject to a $1,000-per-month withdrawal limit. The issue is a complex one, because deposits were frozen or limited for varying lengths of time at different institutions.

Funds in Old Court no longer earn interest, although they did for most of last year, but deposits in the other three S&Ls continue to accrue interest even though it cannot be withdrawn.

Under generally accepted tax principles, interest income is taxable when it is earned. So a taxpayer who invests his money in a 10-year certificate of deposit must pay taxes each year on the interest the account earned that year.

The S&L depositors, however, did not voluntarily agree to get their interest later rather than sooner. Many of the deposits are frozen in passbook savings accounts that ordinarily would make the interest accessible soon as it is earned.