U.S. legislation to press China to revalue its currency narrowly cleared a Senate procedural vote before a formal vote later on Thursday but it faced stronger opposition in the House of Representatives.

The bill passed a cloture vote ending debate by a margin of 62-38 -- two votes more than the minimum required support of 60 and an erosion of support from a 79-19 vote on Monday.

Senate Majority Leader Harry Reid said after the vote he hoped to finish action on the bill later in the day.

The Currency Exchange Rate Oversight Reform Act of 2011, is the newest version of nearly annual legislative efforts to pressure China on currency policy since 2005.

It has gained support from many lawmakers alarmed at high unemployment ahead of U.S. elections in 2012.

But it has drawn warnings from Beijing that it could trigger a trade war, and the White House voiced concern the measure, which calls for U.S. duties on imports from countries with deliberately undervalued currencies might conflict with international trade rules.

A Senate vote to pass the bill later on Thursday would send the bill to the Republican-controlled House.

House Speaker John Boehner on Thursday reiterated his opposition to the bill, calling it wrong and dangerous because it posed the risk of retaliation from China that could spiral into a trade war.

Many economists say China holds down the value of its yuan currency to give its exporters an edge in global markets. China says it is committed to gradual currency reform and notes that the yuan has risen 30 percent against the dollar since 2005.