The White House, seeking to head off a congressional stampede toward a pre-election tax-cut bill, agreed yesterday to work jointly with House and Senate Democrats to develop a partywide tax-cut strategy before mid-July.

In a meeting with key Democratic senators, President Carter's economic advisers laid the groundwork for a series of White House-congressional negotiations similar to those that preceded Carter's March 14 anti-inflation plan.

The aim of the move yesterday was to regain some measure of White House control over the new tax-cut drive and prevent a runaway by Senate Democrats, who -- panicked by Ronald Reagan's new tax-cut proposal last Wednesday -- bolted from Carter's stand and pledged to draft a tax-cut bill by Sept. 3.

Carter's top economic advisers have been discussing a 1981 tax-cut proposal of between $20 billion and $30 billion, but apparently are not yet agreed on how soon they believe the administration should unveil its plan.

Earlier, sources had reported that Carter's advisers had agreed to urge the president to propose a tax cut soon, but others asserted last night that no such consensus had been reached.

White House strategists were jolted Thursday when Senate Democrats, edgy about Reagan's call earlier this week for a $36 billion tax cut in 1981, deserted Carter and promised a tax-cut plan of their own by Sept. 3.

The senators' flip-flop had ripple effects throughout the Capitol. Rep. Al Ullman (D-Ore.), chairman of the House Ways and Means Committee, who earlier had opposed any tax bill this year, told House leaders later that they, too, would have to act.

A tax-cut task force appointed by Senate Democrats, led by Sen. Lloyd M. Bentsen (D-Tex.), began moving yesterday to consider various options for inclusion in a tax-cut package. Ullman also is reviewing several alternatives.

Carter is scheduled to meet with House Democratic leaders Tuesday to discuss tax-cut strategies. The president is at Camp David this weekend after his return from the Venice economic and political summit.

Yesterday, House Speaker Thomas P. (Tip) O'Neill Jr. (D-Mass.) served notice that the House would not take action until Carter makes his decision, presumably by mid-July. O'Neill told reporters at his daily news conference that it was "inconceivable" that the House would pass a tax-cut bill before the November election, but he said a post-election session is a good possibility.

Carter is described by officials as still reluctant to push too quickly in unveiling a 1981 tax-cut plan, both to avoid reviving inflation psychology around the nation and to avert charges that he is zig-zagging again.

However, key administration officials conceded that there is little real likelihood that the president would be able to stem the tide that rose when Senate Democrats acted Thursday. They said the party might splinter if he did.

Administration officials had talked earlier of a possible $15 billion-to-$25 billion tax cut for 1981, but apparently have revised that to the $20 billion-to-$30 billion range.

Although strategists have not agreed on details, officials have made clear that at least part of the administration's package will involve faster depreciation writeoffs for business investment.

Officials also are considering a plan by Rep. Richard A. Gephardt (D-Mo.) that would ease the burden of the scheduled Jan. 1 increase in Social Security taxes by giving a tax credit to offset the rise.

They hinted that, in any case, Carter's plan would provide smaller tax cuts for individuals and a higher proportion of incentives for investment than Reagan's plan. The administration hopes to portray its own tax bill as "anti-inflationary," and attack Reagan's as likely to revive the wage-price spiral.

Administration strategists conceded yesterday that they were surprised by the response to the Reagan package and annoyed that it had received such attention as a "new" proposal. The plan is a first-year installment of Reagan's previous policy.