The Government's Search and Surveillance Bill has passed its third and final reading.
The bill, which replaces temporary legislation covering current police investigations, was passed by 61 votes to 57; National, ACT and United Future voted in support.
Justice Minister Judith Collins says the legislation brings search and surveillance powers up to date with 21st-century technology while safeguarding human rights.