The key to the somewhat complicated economic stimulus package announced Friday by President-elect Jimmy Carter is that it covers a two-year period.

By scheduling tax reductions and spending programs that cover this year and most of next, Carter has finessed two tricky problems.

First, he has recognised that everting a possible recession in 1978 or 1979 is as important as making good on his short-term promise to get the economy moving faster this year.

Second, he has been able to propose a program of roughly $30 billion, without adding more than $10 billion to $15 billion to the fiscal 1977 deficit. What happens in 1978 will depend in part on the extent of economic recovery.

The two-year approach will enable Carter to schedule more programs directly related to job-creation - as demanded by his labor supporters and by influential congressional leaders - than his own economists originally wanted to include.

In tone, the package is oriented toward Democratic Party political commitments,emphasizing spending for jobs and tax cuts focused on low-income groups. By contrast, President Ford's recent proposal of a $12.1 billion tax cut for calender 1977 concentrated on tax relief for middle-income groups and more liberal tax treatment for business.

Of Carter's propsed tax reductions, only about $6 billion - $4 billion for business - appear to be permanet. This leaves Carter considerable flexibility for future tax reform proposals.

Carter leaned on the advise of his Office of Management ad Budget Director-designate, Thomas B. (Bert) Lance, that to sponsor a stimulus of more than $15 billion this year would push the federal deficit for fiscal 1977 beyond $70 billion or $75 billion and risk squandering the business community's growing sense of confidence in the incoming administration.

Even so, some Carter aides acknowledge that the two-year program will make it harder to reach the President-elect's goal of a balanced budget in fiscal 1981. Lawrence R. Klein, who headed Carter's advisory group during the campaign, thinks that the priority given to the recovery program - which he agrees is necessary - probably postpones the balanced budget goal by a year or two.

Experts said yesterday that Carter's decision to put more than a one-year "quickie" stimulus into place was probably the most important aspect of the package. "It greatly reduces the possibility of a real recession in 1978 or 1979," tax expert Joseph A. Pechman said in a telephone interview.

Carter's team has been concerned that, even with a "shot in the arm" for 1977, the normal business cycle would produce a true recession beginning in 1978. The experts foresaw increasingly tough structural unemployment problems, tight money markets, and a new downturn in housing.

By stretching the economic stimulus into fiscal 1978, including a substantial commitment to public works and public service jobs, they say the new program may avet a serious economic falloff in 1978.

But the most innovative and potentially the most controversial part of the Carter package is a proposed $2 billion permanet tax reduction for business, allowing a credit against business income taxes of 5 per cent of employers's annual payroll taxes into the Social Security fund.

Business leaders clearly would have preferred that such a tax reduction be provided by increasing the investment credit. Although economists agreed yesterday that the credit against business taxes would have less of a stimulus than would the investment credit, it has certain advantages.

Economist Arthur M. Okun pointed out, for example, that the Social Security credit would have a small anti-inflationary effect by cutting business wage costs.

Of even greater potential economic significance, the credit against payroll taxes can be considered the first step toward Treasury financing of Social Security benefits. In effect, the $2 billion that business does not have to pay into the Social Security Trust Fund will be replaced out of general Treasury revenues. Some economists have urged that the burden of payroll taxes on both employees and employers be reduced by tapping, in part, the government's general funds.

Pechman, who said that such areform of the payroll tax is "a desirable thing," would nevertheless have preferred the investment credit as a stimulus to the economy at this time. Friday's briefing in Plains, Ga., indicated that Carter might yet change his mind on this issue.