Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

A federal court in Wisconsin on Friday overturned the conviction of Brendan Dassey, who was accused of helping his uncle kill Teresa Halbach, in a case brought to the national spotlight in the Netflix documentary "Making a Murderer."

Dassey was arrested at the age of 16 and sentenced to 41 years in prison on charges of first-degree intentional homicide, second-degree sexual assault and mutilation of a corpse after he confessed that he helped his uncle, Steven Avery, kill Halbach in 2005 Manitowoc County.

Brendan Dassey is escorted into court for his sentencing Thursday, Aug. 2, 2007, in Manitowoc, Wis. ASSOCIATED PRESS

Magistrate Judge William E. Duffin in Milwaukee ordered that Dassey be released in 90 days, unless the case is appealed, according to court documents.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

Duffin wrote that investigators made repeated claims to Dassey that they already knew what happened, and falsely promised that he had nothing to worry about.

"These repeated false promises, when considered in conjunction with all relevant factors, most especially Dassey’s age, intellectual deficits, and the absence of a supportive adult, rendered Dassey’s confession involuntary," Duffin wrote in the order.

"Dassey's confession was, as a practical matter, the entirety of the case against him on each of the three counts," Duffin wrote.

Northwestern University’s Center on Wrongful Convictions of Youth legal team based in Chicago took Dassey’s case to federal court in Wisconsin in 2014, in hopes that the government would consider whether he had been imprisoned illegally, according to NBC Chicago.

Related: Steven Avery's Lawyer: Forensic Tests Could Clear Him

Lawyers with the center argued that Dassey's original attorney wanted to get him to plead guilty and said that Dassey was coerced by investigators into giving a false confession.

A spokesman for the Wisconsin Department of Justice declined to comment on Duffin's ruling, and said the department was still reviewing Duffin's order.

Ken Kratz, the former Calumet County, Wisconsin, district attorney who prosecuted Avery and Dassey, has defended the way he handled the case. Avery was tried and convicted separately in the killing, but he maintains his innocence.

An attorney for Avery said Avery is thrilled with the judge's ruling. Kathleen Zellner said she was visiting Avery on Friday and he was "so happy" for Brendan Dassey. Zellner said in a statement that she's confident that Avery's conviction will eventually be overturned "when an unbiased court" reviews new evidence.