Labour has declared a "fightback" was under way after retaining Inverclyde and claimed the Scottish National Party's "bandwagon has ground to a halt".
In a by-election result which will bring some relief to Labour leader Ed Miliband, the party's Iain McKenzie held the seat with a majority of 5,838 - less than half the 14,426 margin gained by his predecessor David Cairns whose death sparked the poll.
A tight contest between the two parties had been forecast in the Labour stronghold after the nationalists swept the board in May's Scottish parliamentary elections.
But speaking after the count Mr McKenzie said: "With a result like this I think we can safely say the SNP bandwagon has ground to a halt. Labour won this election because we listened hard and took nothing for granted. This is the start of Labour's fightback and there will be a lot more listening to do over the coming months and years."
The SNP increased its share of the vote on the 2010 general election, and said the 9% swing in its direction had continued the momentum that carried it to a resounding victory in the Holyrood elections.
The SNP's Inverclyde candidate Anne McLaughlin insisted the fight for independence will continue. She said: "I've been fighting with the SNP for 23 years, I will never give up until we have independence and after we get independence we have a country to sort out."
It was a campaign fought in the shadow of the death of Mr Cairns, a groundbreaking MP whose election sparked a change in the law which had banned former Catholic priests from taking up a seat.
The SNP claimed it was Labour's "negative campaign" that led to its collapse in the Scottish Parliament elections.
But the by-election offered Labour the chance to accuse the SNP of negativity following a controversial Facebook posting by George Adam, MSP for nearby Paisley, who wrote that he would need "jabs" after a visit to Greenock.
Mr McKenzie said: "I get angry when I hear people talk down my community. The people who came here asking for our votes, and then suggested they need jabs to get out of Inverclyde, are beneath contempt."