WASHINGTON -- The House of Representatives passed a three-week stopgap funding bill on Tuesday by a vote of 271 to 158, fending off the threat of a government shutdown despite nay votes from 54 Republicans.

But the size of that opposition group served to demonstrate the growing tension between Republican leadership and the conference's more extreme wing, which threatens to derail negotiations over how the government should be funded for the remainder of the year. Both Republican and Democratic leaders are watching them closely.

Among the defectors were nine GOP freshmen, part of a group the House leadership is finding almost impossible to control, according to a top Republican aide. Part of their stated opposition to the short-term bill was that it did not include riders to defund Planned Parenthood and health care reform, two of the most controversial provisions of a longer-term continuing resolution passed by the House last month.

House Speaker John Boehner (R-Ohio) acknowledged some tension within his conference over the short-term funding after Republican Study Committee Chairman Jim Jordan (Ohio) and others announced that they planned to vote against the three-week bill.

"I understand some of our members want to do more, but what is it in this bill they disagree with? Nothing," Boehner told reporters after a Republican conference meeting on Tuesday morning. "I'm confident this bill will pass and we'll send it to the Senate."

But as the House and Senate attempt to move forward on a compromise for a longer-term spending bill, riders could spell disaster. Republicans currently hold 241 seats in the House to the Democrats' 192, with a majority threshold at 217 votes. That creates a tricky balance for House GOP leaders as they determine how to move forward. Go too far in one direction, and the bill could alienate Senate Democrats, who rejected the House's first attempt at a longer-term funding bill. Go too far toward the center, though, and Republican leaders could face even more defectors, and fail to pass a bill through the lower chamber.

The GOP can only lose 24 votes from within its conference and still pass a bill without support from House Democrats, many of whom have opposed deep cuts to government programs.

If the final compromise strips riders on Planned Parenthood and health care reform, many of the Republicans who voted against Tuesday's bill would likely defect again, said Rep. Steve King (R-Iowa), the author of the longer-term resolution's provision to defund health care.

King is collecting signatures for a letter that states he and other members will vote against the longer-term bill if it does not include provisions to stop funding for the health care law. He told reporters after the vote that "a good number" of Republicans have signed onto the letter to House leadership, but declined to give names or a specific figure.

One likely source of dissent could be the group of 13 freshmen who a GOP aide told HuffPost the leadership has had trouble controlling: Reps. Justin Amash (Mich.), Mo Brooks (Ala.), Paul Gosar (Ariz.), Andy Harris (Md.), Tim Huelskamp (Kan.), Raul Labrador (Idaho), Mick Mulvaney (S.C.), Steve Pearce (N.M.), David Schweikert (Ariz.), Steve Southerland (Fla.), Tim Walberg (Mich.), Joe Walsh (Ill.) and Rob Woodall (Ga.).

Each of the 13 supported riders and a failed amendment that would have expanded the $61 billion cut bill. All 13 voted for the King amendment that would cripple the implementation of health care reform, and all but one voted for the Pence amendment to defund Planned Parenthood. Amash (R-Mich.), the only non-"yes" vote on the amendment among the group, voted "present" because it singled out a specific organization -- a violation of the Constitution -- according to a message on his Facebook page.

Most of these freshmen -- Amash, Harris, Huelskamp, Labrador, Mulvaney, Pearce, Southerland, Walberg and Walsh -- voted against the three-week funding bill. Amash has said he voted against the last stopgap funding bill because it did not go far enough in cuts.

Huelskamp told Politico on Monday that his constituents were more excited about the riders in the House's funding bill than the budget cuts. He announced he would vote against Tuesday's short-term bill because of the lack of riders.

"There have been ongoing concerns among the freshmen, and among the Republican Study Committee, about the strategy of setting these riders aside for five weeks and negotiating away the cuts we did make," Huelskamp said. "You have to send a clear message to the Senate and the president."

Brooks voted for the short-term funding, but told HuffPost that "at some point we have to draw the line," hinting he may vote against a final compromise if it does not make sufficient cuts. He said he is "proud of his reputation as independent-minded" and said the House leadership had never asked him to vote one way or another on specific legislation.

"My first priority is always voting for what I think is in America's best interest," he told HuffPost. "I'm not here to please Republicans or Democrats, I'm here to do a job, to try to protect America from bankruptcy."

Republican leaders seem to be on the same page for now, showing little flexibility over the $50 billion figure demanded for cuts in the House's longer-term continuing resolution. Boehner said on Tuesday that he wanted the Senate to pass a funding bill before the two chambers could find common ground on government funding.

The House GOP's rigid stance on funding cuts has drawn fire from Democrats. House Minority Whip Steny Hoyer (D-Md.) criticized his counterparts during his weekly briefing with reporters on Tuesday, arguing that the GOP should create a less extreme resolution that could pass the Senate.

"They don't know what they can get votes for on their side, because a lot of their members want exactly what they had voted for and nothing less," Hoyer said. "There are a lot of those people who are very new to the legislative process, but I can't believe the new [members] are compromising their families and businesses and communities."

Ryan Grim contributed reporting.