There were cries of "shame" and "disgrace" by MPs when the result was announced to the packed chamber.
Whipped by the Government, Tory MPs threw out an amendment to the Firearms Bill which would have banned all handguns by 306 to 281 votes, a Government majority of 25.
Robert Hughes, one of four Conservative MPs to vote against the government, warned that the vote "will haunt the Government through the general election".
Ann Pearston, spokeswoman for the Dunblane Snowdrop campaign, said: "It is not the end. The campaign will continue, though maybe not in the same form. We will ask the British electorate when they vote to remember how this Government betrayed their trust."
Referring to Labour, Liberal Democrat and Nationalist parties, she said on BBC TV: "If you support a complete ban, back them."
Mr Hughes was joined in defying the Tory whip by Terry Dicks, Hugh Dykes and David Mellor, the former Cabinet minister, who led a impassioned attack on Michael Howard, the Home Secretary, from the Tory backbenches.
Mr Mellor accused the Home Secretary of being impervious any contrary opinion.
"Because they're not having a free vote, more timorous spirits than me will vote with the Government against their consciences so the Government will have a pyrrhic victory. They will win the vote but they will lose the argument," he said.
Appealing for Tory MPs to support the Government, Mr Howard, admitted that shooters could use the compensation to buy .22 semi-automatic weapons which will still be allowed in gun clubs.
Mr Howard told MPs "If there were to be a complete ban there is a real danger target shooting would continue to take place outside the law ... That would lead to a lessening of the protection for the public," he told MPs.
An attempt to introduce further amendments to the Bill for a total ban on handguns in Scotland was promised by Alex Salmond, the Scottish National Party leader. He blamed abstaining Labour and Liberal Democrat MPs for the failure of the Opposition amendment.
The rebel Tory MPs said the vote would have gone in favour of a total ban if there had been a free vote. The Government was confident of victory, after being told that those Ulster Unionists at Westminster would support it. Douglas Hogg, the Agriculture Secretary, was told not to return for the vote from a meeting of ministers in Brussels.
George Robertson, Labour's Scottish affairs spokesman, described the vote as a "moment of critical decision, a moment when parliament would be on trial".
The calls for a total ban were strengthened by news of the fatal shooting of four children in the United States. The children had been shot in the head with a .22-calibre gun. Their bodies were discovered in South Carolina on Sunday night.
With parents of those murdered both at Dunblane and Hungerford watching from the Commons gallery, the Home Secretary, told MPs the Government's Bill would give Britain some of the toughest gun laws in the world, as a response to the Dunblane tragedy, in which Thomas Hamilton killed 16 schoolchildren and their teacher in March. Under the Bill, which went further than the recommendations of Lord Cullen's inquiry, all guns above .22 calibre will be banned, and smaller-calibre weapons will be available for use only at gun clubs under strict conditions.
Some senior Tory MPs led by Sir Jerry Wiggin, MP for Weston-super-Mare, arguing that the Bill went too far and that the government should have stuck to the recommendations of the Cullen report.Reuse content