WASHINGTON — The Senate on Wednesday rejected separate bills to regulate data centers and limit stock trading by members of Congress.

Battleground Republicans were hoping to campaign on the bills, but Democrats blocked both measures, saying they don’t go far enough.

The two votes failed on the Senate floor in a final burst of business before senators headed home for the election, now less than five weeks away.

Republicans scheduled votes on the two campaign issues, hoping to deliver something for battleground Republicans to campaign on.

The Stop Insider Trading Act would prohibit most members of Congress and their spouses from trading stocks. The Ratepayer Protection Act is designed to prevent data centers from driving up local electricity rates.

“It would simply promote the adoption of a standard that would require data centers to shoulder the electricity costs associated with their operation and construction,” Senate Majority Leader John Thune, R-S.D., said of the data center bill.

Democrats argued the data center bill lacks teeth and is more about political messaging. On the stock trading bill, they accused Republicans of adding a poison pill in the form of new voter ID requirements, and criticized the measure for not forcing lawmakers to sell stock they already own.

“The Republican toothless stock trading bill is as ineffective as a screen door on a submarine,” said Senate Minority Leader Chuck Schumer, D-N.Y.

The spread of data centers has emerged as a potent campaign issue in states such as Ohio. Incumbent Sen. Jon Husted, R-Ohio, sponsored the bill in part to counter relentless attack ads from his opponent, former Sen. Sherrod Brown, focused on Husted’s past support of data centers.

“If Democrats block this bill, they will prove beyond a shadow of a doubt that they do not care about affordability,” Husted said on the Senate floor.

Despite failing in the Senate, both bills had bipartisan support in the House. The Ratepayer Protection Act won the support of nearly all House Democrats, but in the Senate, just four Democrats backed the legislation.