A squabble between the states and the fereral government over $200 million a year in "windfall profits" on state Social Security tax collections my be headed for compromise.

The dispute involves payments for state and local government employes enrolled in Social Security. About 9 million workers are involved, with state and local governments collecting $12 billion a year in oatroll taxes that they must over to the Social Security trust funds.

Although the local agencies collect the payments weekly or every other week through withholding on payrolls, current rules allow them to hold the money for three months before turining it over to Social Security. Large private employers must turn in the money every week or two.

While holding the money, state and local governments put it into shortterm federal or state securities or banks, where it draws interest. Millions of dollars come to them this way in "windfall profits."

The social Security Administration and former secretary of health, education and welfare Joseph A. Califano Jr. calculated that if state and local governments were forced to turn over the money to the fedreal government 15 days after the end of the month in which collected, it could be invested in U.S. government bonds and bring $200 million a year in interest for the hard-pressed Social Security system.

So Califano formulated a tentative regulation last November proposing a payments speedup.

When the National Governors Association objected, Gaylord Nelson (D. Wis.), chairman of the Senate Social Security subcommittee, and the Senate Majority Leader Robert C. Byrd (D.W.Va.) warned that they might move to block the regulation.

The states complained not only that they would lose the interest but also that they couldn't get the payroll tax collections together and send them in within 15 days of the end of the month. The states said 22 days after the end of each month would be a minimum.

Nelson has now developed a compromise that has 40 co-sponsors, including a majority of the Senate Finance Committee, which has jurisdiction. It gives the states 30 days after the end of each month to send in the money, and it is estimated that this will still allow the states to keep about $90 million out of the interest payments they now earn. Social Security would end up with $110 million a year extra by getting the basic payments sooner and investing them.

The governor's association says it can live with the Nelson compromise. Senate sources said HEW also has given indications it can accept the compromise.

Nelson believes his plan can move swiftly. "There is no justification for allowing the states to retain some $200 million a year in interest income at the expense of the Social Security tust funds," he said in a statement.

"However, any change in the schedule must be reasonable."