A US federal appeals court has rejected efforts by the American Civil Liberties Union (ACLU) to stop bulk collection of millions of Americans’ phone records.

The 2nd US Circuit Court of Appeals in Manhattan said on Thursday that Congress wanted the National Security Agency (NSA) program to continue during a six-month transition period before a new law takes effect.

"An abrupt end to the program would be contrary to the public interest in effective surveillance of terrorist threats, and Congress thus provided a 180-day transition period," Circuit Judge Gerard Lynch wrote for a three-judge panel. "Under the circumstances, we will defer to that reasonable decision."

In May, the appeals court abolished the mass spying program as illegal and in violation of Americans’ privacy rights.

Congress later approved a more limited method that will take effect in November. The ACLU sought to stop the surveillance before the launch of the new scheme.

But the 2nd US Circuit Court argued that a sudden halt to the current program would harm the public interest in effective surveillance of terrorist threats.

The US mass spying program was first disclosed in 2013 by NSA contractor Edward Snowden the agency which brought it under harsh criticism both in the US and around the world.

Snowden, who lives in Russia where he has been granted asylum, has said that US government surveillance methods far surpass those of an ‘Orwellian’ state, referring to George Orwell’s classic novel “1984,” which describes a society where personal privacy is continuously invaded by spy agencies.