Two Scottish National party members of the Scottish parliament who led a rebellion against proposals for an independent Scotland to join Nato have resigned in protest.

John Finnie and Jean Urquhart, both MSPs in the Highlands, announced they had quit after the party very narrowly voted to overturn the decades-long ban on Nato membership, following an intense conference debate on Friday.

Their resignations mark the first major revolt against Alex Salmond's leadership since the SNP won power at the Scottish parliament in 2007, illustrating the scale of the controversy over the new pro-Nato policy.

The rebels insisted it was hypocritical and probably unworkable for the party to support the idea of Scotland joining a nuclear-armed military alliance while at the same demanding that the UK removes the Trident nuclear weapons system from its base on the Clyde.

Finnie, a former police officer who joined the SNP at 16 and has been an open critic of Scottish government policy, said: "I cannot belong to a party that quite rightly does not wish to hold nuclear weapons on its soil, but wants to join a first-strike nuclear alliance.

"Although I envisage that I will continue to share common ground with the SNP on many issues, I cannot in good conscience continue to take the party whip."

Urquhart, a Campaign for Nuclear Disarmament member for 35 years who been considering whether she might resign before Friday's vote, said: "The issue of nuclear disarmament and removing Trident from Scotland's waters is a red-line issue for me, and I could not remain committed to a party that has committed itself to retaining membership of Nato.

"We are both steadfast in our belief that Scotland should be an independent country, and will actively and positively campaign for a yes vote in 2014. We believe in an independent Scotland, not a Nato-dependent Scotland."

Finnie said other Nato rebels at Holyrood had decided to stay in the party and fight against it internally. One, Sandra White, the MSP for Glasgow Kelvin, has indicated she will ask the party's leadership to produce evidence that Nato will allow an anti-nuclear independent Scotland to join the alliance, while it also demands that the UK removes Trident from the Clyde.

Salmond, the first minister, said "I'm saddened that Jean and John have decided to resign from the party. They have been excellent servants to the SNP."

Both MSPs will now sit as independents. Their resignations still leave Salmond with a healthy majority at Holyrood over his nearest rivals, Labour, but cuts the SNP's absolute, technical majority down to just two seats.

After winning power in 2011 with 69 seats, the SNP will now have 65 MSPs, compared with 37 for Labour.

The SNP lost one backbencher after Tricia Marwick became presiding officer at Holyrood. It lost another after Bill Walker, the MSP for Dunfermline, was dismissed by the SNP and now sits as an independent after allegations emerged about violence towards previous partners and children.

However, the four opposition parties combined – Labour, the Tories, Lib Dems and Scottish Greens – have 59 seats. Margo MacDonald, the former SNP MP, sits as an independent. While she and all three former SNP MSPs who have joined her as independents do not count towards the SNP majority, they are expected to vote for Salmond on all key votes on the independence referendum.

Isobel Lindsay, the vice-chair of Scottish CND, said the group had "great respect for John Finnie and Jean Urquhart's integrity. We are sure that they will continue to work for a non-nuclear independent Scotland that is not part of an aggressive military alliance."