The Green Party and New Zealand First said they could not support the legislation in its current form, despite a raft of changes which further restrict spy agencies' ability to monitor suspected terrorists.
National's coalition partners, United Future and Act, who had expressed reservations about warrantless surveillance, said the amendments meant they would not oppose the bill passing into law next week.
Prime Minister John Key said the Government would accept the changes recommended by a select committee and he was "pleased" that Labour had come on board.
The Labour leader, Andrew Little, said the rushed process was "appalling" and "sloppy" but the concessions had "balanced what was previously a very unbalanced piece of legislation".
The changes Labour secured in the select committee were significant.
Intrusive new surveillance powers will be permitted only in relation to terrorist activity, not the Security Intelligence Service's wider activities. Emergency, warrantless surveillance of suspects will be limited to 24 hours instead of 48 and subject to stricter oversight and more frequent reporting. And suspects who have their passports cancelled for three years will be able to appeal and apply to get them back.
Mr Little was asked if Labour had softened its stance on security, given it had opposed changes to the Government Communications Security Bureau (GCSB) last year.
He said the counter-terrorism bill was different because it had a sunset clause.
That expiry date for the interim legislation was brought forward by the committee to 2017, which means a full review of intelligence and security legislation will have to be completed in this parliamentary term.
New Zealand First leader Winston Peters said his party would not support the bill unless further changes were made at the committee stage.
He was uncomfortable with the speed at which it was being passed into law and wanted reassurances spy agencies would be "restrained" in their use of visual surveillance.
The Green Party said it would vote no because the Government had not made the case for the changes.
Co-leader Russel Norman said: "Unwarranted surveillance is still unwarranted surveillance even if it's only for 24 hours."
By Isaac Davison of the New Zealand Herald