"I can completely understand the scepticism of some internet policy activists," Justice Minister Heiko Maas told a press conference in Berlin.
Maas, a member of the Social Democratic Party (SPD), had previously resisted pressure from his Christian Democratic Union (CDU) coalition allies to introduce the law.
But the plan to retain computer IP addresses, telephone connection data and mobile phone location data will now go ahead after pressure from CDU Interior Minister Thomas de Maizière.
"The retention times are much shorter and access to the data is much more difficult than before [in previous versions of the law]," Maas said, claiming that he had achieved a reasonable compromise.
Police and other authorities will only have legal access to the data as part of investigations into serious crimes, such as terrorism, murder, manslaughter or sexual abuse.
Judges will have the power to grant access, and there will be no right of access to the data of professionals with a duty of secrecy, including lawyers, doctors, elected representatives and journalists.
But Maas' assurances didn't go far enough for internet policy activists.
"Just a few months ago, the Justice Minister was a committed opponent of this move, and the draft presented today is only slightly different from the previous versions that failed," Markus Beckedahl of Netzpolitik told The Local.
"This cabinet decision is totally disproportionate. The government isn't in a position to demonstrate that it's necessary, which they would have to do to justify such a step against human rights."
One activist asked Maas during the Berlin press conference how the government planned to justify the law.
"I can't justify the necessity [for this law]," Maas responded, although he went on to argue that the law would allow previously unsolvable crimes to be unravelled.
A Europe-wide attempt to introduce data retention was quashed by the Court of Justice of the European Union (CJEU) in 2014, while a German-only version foundered in the Constitutional Court in 2010.
The CJEU found that the pan-European version breached human rights, while the German judges said the home-grown option was unconstitutional.
But de Maizière said that "I think we'll have good arguments before parliament and before the courts," avoiding a repeat of the failure.
Beckedahl argued that the government was minimising the space for proper debate.
"They're whipping this through cabinet and parliament in less than six weeks," he said.
The opposition Green and Linke (Left) parties said the plans were unconstitutional and disproportionate.
And the CDU's former coalition allies, the Free Democratic Party (FDP) warned that they would challenge the law before the Constitutional Court.
"There will be many challenges," Beckedahl said, "and we hope that the Constitutional Court will declare the law unconstitutional after it's passed, just like in 2010."