Treasury Secretary James A. Baker III announced yesterday that the budget deficit for fiscal 1987 will be $20 billion less than anticipated, mostly because of the tax revision that produced an upsurge in revenue as of April 15.

After a Cabinet meeting one day before federal agencies were to submit $13 billion in additional budget cuts for fiscal 1988, Baker said:

"The president is extremely pleased to note that the fiscal 1987 deficit is going to be reduced significantly more than we originally anticipated. We think that we'll see a deficit reduction for fiscal 1987 of something in the neighborhood of $66 billion, down to a level of $155 billion or so, which is of course significantly below the $175 billion we originally anticipated."

That still would leave the deficit about $10 billion above the $144 billion target set in the Gramm-Rudman-Hollings balanced budget law.

But Baker said the preliminary figures prepared for August's midyear administration budget analysis is "very, very good" news, the "consequence of increased revenues from tax reform."

Budget director James Miller said that because the new tax laws removed preferential treatment of capital gains, people sold off much of their stock holdings at the end of last year and paid taxes this year at the more advantageous rate.

Federal agencies are scheduled to give Miller a new round of budget reductions totaling $13 billion by noon today to meet the fiscal 1988 deficit target of $108 billion.

He said the Defense Department was included in the demand for additional cuts but said none of the cuts would harm national security.