Democrats on the House and Senate tax-writing committees broke through their logjams yesterday and agreed to billions of dollars in tax increases for 1988 to help reduce the budget deficit.

Democrats on the Senate Finance Committee approved about $7.6 billion in higher taxes, with more tax-increasing action expected today. Democrats on the House Ways and Means Committee completed preliminary work on a $12 billion-plus measure that includes new restrictions on interest deductions for homeowners who take out the increasingly popular home-equity loans.

The swift action in both committees was a surprising turnaround from the slow pace of last week. Republicans on both panels are boycotting the drafting sessions, and until yesterday Democrats had shown little enthusiasm for raising taxes.

President Reagan has vowed to veto any tax increases, and there also is opposition to higher taxes in both houses. The full Ways and Means Committee is to vote on the bill Thursday. The Senate Finance Committee also is expected to vote this week.

The Ways and Means plan would raise more than the amount required in congressionally mandated deficit-reduction targets, but Chairman Dan Rostenkowski (D-Ill.) said it would not raise taxes for lower- or middle-income taxpayers.

The Ways and Means plan would change the restrictions on home-equity loans by limiting interest deductions to borrowings of $100,000 or less. Last year's tax-revision law limited deductible interest on a new home-equity loan to an amount no greater than the original cost of the house plus the value of improvements. Last year's revision also allows interest deductions on higher amounts if the proceeds were used for medical or educational expenses.

The House plan also would deny the interest deduction for the portion of any home mortgage that exceeds $1 million and would deny interest deductions on loans used to buy boats or mobile homes used for "transient" purposes rather than as a prime residence. The measure also includes new restrictions on tax-favored partnerships and the tax benefits of corporate takeovers.

An ebullient Rostenkowski said the plan would not raise excise taxes or increase income-tax rates for individuals or corporations but added that some of its elements are controversial.

"I'm sure when word gets out about what we've done, the Republicans will have a lot of fun taking pot shots at us," Rostenkowski said. ". . . I'm sure there's enough pepper in this bill that it's going to aggravate some people."

Chances for passage by the full Ways and Means Committee, which is dominated by Democrats, are considered good. In the Senate Finance Committee, Democrats not only hold a slimmer majority but tend to adhere less rigidly to party discipline.

Although Reagan has vowed to oppose all new taxes, several elements of the two Democratic tax packages were proposed in his fiscal 1988 budget. The most important are user fees for IRS rulings, Customs Service processing and various licensing functions of the Bureau of Alcohol, Tobacco and Firearms.

Both committee measures also would extend the 3 percent tax on telephone bills scheduled to expire at the end of this year. They would also repeal an estate-tax loophole created by last year's tax-revision law and accelerate the collection of tax payments by corporations.

Senate Finance Committee Chairman Lloyd Bentsen (D-Tex.) called his panel's tax plan "the kind of package we could pass through the committee and through the floor. . . . I think we have an excellent chance of being able to raise the kinds of funds we are committed to raise."

Bentsen said the final Senate measure would raise taxes about $9.5 billion. It also includes $2 billion from enhanced IRS enforcement to reach a total of $11.5 billion. Democrats on the Finance Committee are insisting that no more than half of the $23 billion in required deficit-reduction come from higher revenues.

Republicans on the House and Senate committees have refused to participate in drafting a tax bill. In the House, GOP members of Ways and Means want more spending cuts and a smaller tax bill, while in the Senate, Republican Finance members have suggested waiting until upcoming deadlines under the Gramm-Rudman-Hollings deficit-reduction law increase pressure to reduce spending.

Neither house is considered a sure bet to pass a tax bill, especially if Reagan reiterates his veto threat.