Comptroller General Charles A. Bowsher yesterday accused President Reagan of violating the Constitution by defying a federal law designed to strengthen the General Accounting Office's role in handling bid protests.

The 1984 Competition in Contracting Act gave the GAO authority to hold up a federal contract if a valid bid protest was on file with government auditors. The Reagan administration views that provision as unconstitutional, and last year the Justice Department and the Office of Management and Budget ordered agencies to ignore it.

Yesterday, in testimony before the House Government Operations subcommittee on legislation and national security, Bowsher weighed into the simmering controversy by contending that "it is the president who has violated the separation of powers doctrine by defying a duly-passed act of the Congress through the actions of the attorney general and the director of OMB."

The administration has argued that the comptroller general, who heads the GAO under a fixed 15-year term, is a representative of the legislative branch and thus cannot hold up contracts awarded by the executive branch. Bowsher argued that he is an officer of the United States, appointed by the president and confirmed by the Senate, and not subject to the "whims" of congressional influence.

"Disobedience of the law is itself a matter of serious constitutional significance," Bowsher testified. "We cannot find any justification for the action taken to deliberately avoid the law in this case."

Bowsher's position was supported at the hearing by several constitutional law authorities, including a representative of the American Bar Association.

Eugene Gressman, a University of North Carolina law professor, said that the administration's action "constitutes a willful disobedience of the will of Congress. In our constitutional system of government, such a refusal by the executive to 'take care that the laws be faithfully executed' cannot and must not be tolerated."

The subcommittee has scheduled a second hearing next week to hear testimony from OMB Director David A. Stockman and Attorney General Edwin Meese III.