The budget-dominated 97th Congress staggered wearily home yesterday to campaign after putting the brakes on its 20-month-long scramble to keep pace with President Reagan and his program for radical change in the country's fiscal and social policies.

It will return at Reagan's behest to tackle a heavy backlog of appropriations bills in a lame-duck session starting Nov. 29, when many of the issues lost in the budget shuffle, from pork-barrel projects to clean-air rules, are expected to emerge anew.

But voters' last view of their lawmakers in action before the Nov. 2 elections was that of a Congress that broke ranks in the 20th month after marching in virtual lockstep with its president for 19 months.

It was a Congress that accommodated most of Reagan's program by making wrenching changes in its own way of doing business, only to balk near the end, when the president demanded more than even the Republican-controlled Senate could deliver.

The break came last month, when Reagan appeared to overreach by vetoing a spending bill that complied with congressional budget targets. Instead he pushed controversial conservative social issues such as abortion and school prayer and finally demanded passage of a constitutional amendment to balance the federal budget just as he was producing deficits of more than $100 billion a year.

Although he was defeated on these issues, the fact remains that the net result of actions so far by the 97th Congress is a staggering legislative achievement for Reagan. Congress gave him most of what he wanted, especially last year, when it approved his massive defense buildup, tax reductions and domestic spending cutbacks.

For most of this year, there was more give-and-take, with Congress forcing Reagan to retrench and accept a tax increase, less than he wanted for defense and more than he wanted for domestic programs. But his priorities still dominated, and the basic thrust of his economic and defense programs remained even after the September setbacks.

Congress returned last month from its Labor Day recess in a restive mood as the elections approached without demonstrable progress toward the economic recovery that the administration kept promising.

And the administration, fully aware that the Democrats planned to make political hay of high unemployment and other results of the lingering recession, was eager to focus attention on other matters, ranging from "budget-busting" spending by the Democrats to the New Right's agenda of social issues.

First to rebel was the Democratic-controlled House, where Reagan had previously capitalized on Democratic divisions to enact most of his tax and spending cuts. In its first major defeat of a Reagan budget initiative, the House overrode his veto of a supplemental appropriations bill for fiscal 1982 that included funds for popular programs such as community service jobs for the elderly and aid for college students.

Then the Republican-controlled Senate, once derided by Democrats as Reagan's rubber stamp, joined the House in overriding the veto, with some of the president's most ardent supporters abandoning him on the issue.

Only days later, the Senate ignored the president's pleas for action on legislation or constitutional amendments to ban abortion and permit school prayer, and the issues were laid aside after long filibusters.

Finally last Friday, a day after Reagan went to Capitol Hill to press personally for passage of the balanced-budget constitutional amendment, the House refused, by a 46-vote margin, to give him the two-thirds majority necessary to pass the amendment, already approved by the Senate.

The vote gave Reagan a list of Democrats to campaign against as big spenders who would not vote to impose constitutional restraints on their own spending instincts.

But perhaps more important, the Democrats, by allowing the vote, blunted Reagan's charge that they were being obstructionist in bottling up the amendment, putting them back on the offensive to attack Reagan on economic issues.

In some of these setbacks for Reagan, including the budget-balancing amendment, his congressional troops mustered majority support but failed because a two-thirds vote was required for enactment. But on other matters, such as the veto override, his opponents were able to mount a two-thirds vote against him.

What these straws-in-the-wind votes mean for the future will hinge largely on November election results. All 435 House seats and about one-third of the 100 Senate seats are being contested.

Heavy conservative losses could spell deep trouble for Reagan in the 98th Congress, but could also embolden him to try for all he can get in the lame-duck session before new members are seated in January.

The post-election session, which could last until shortly before Christmas, is expected to focus on appropriations bills and assorted "riders" that special interests will be pushing as amendments to the money bills.

But a Senate leadership source said Friday night that it appears doubtful that the lame-duck session will accomplish much more than passage of a defense appropriations bill and another stopgap "continuing resolution" to fund the rest of the government.

To an extent, congressional enactment of its first continuing resolution for fiscal 1983 tells as much about the 97th Congress as the ups and downs in its relations with Reagan.

The measure, required because Congress had enacted only one of its 13 regular appropriations bills by the start of fiscal 1983 Friday, was not passed until nearly 24 hours after previous funding expired, meaning that the government was technically broke for nearly a day.

Congress' failure to meet its appropriations deadlines, which has become the rule rather than the exception, is not just the result of congressional dillydallying, although there has been some of that.

The budget has become a juggernaut, pushing everything else to the side, forcing delays and encouraging a sometimes desperate Congress to toss everything into catch-all packages, from the kind of sweeping budget-decreed spending cuts that it adopted last summer to the continuing resolution approved Friday night.

There is a groundswell in Congress for changes in the budget and appropriating process to accommodate the new pressures, but many of the proposed changes are so far-reaching that anything more than cautious fine-tuning is considered unlikely, in the near future at least.

More likely, some say, is more stopgap, catch-all appropriating, especially if Reagan and Congress remain at odds about spending priorities. The next installment, they say, could last until March, when Congress will be starting on the next fiscal year's budget.