Josh Duggar has been released from the Washington County Detention Center on Thursday.

The disgraced TLC star of "19 Kids and Counting" fame was granted release by a federal judge on Wednesday as he awaits trial on charges that he downloaded and possessed child pornography.

Magistrate Judge Christy Comstock ordered Duggar, 33, confined to the home of family friends who have agreed to be his custodian during his release and prohibited Duggar from any Internet-accessible devices pending his July 6 trial on the child pornography charges.

Duggar was indicted on the federal child pornography charges on Friday, a day after U.S. Marshals arrested him. He has pleaded not guilty.

"I have full confidence in the United States Marshal Service to find you if you decide not to comply with these conditions of release, so don’t make me regret this decision," Comstock said after a four-hour hearing conducted over Zoom.

JOSH DUGGAR HAD PORN DETECTION SOFTWARE ON HIS COMPUTER THAT SENT REPORTS TO WIFE ANNA: OFFICIALS

"You won’t, your honor, thank you very much," responded Duggar.

Josh and Anna Duggar have six children.

Josh and Anna Duggar have six children. (Kris Connor/Getty Images)

Duggar starred on TLC’s "19 Kids and Counting" until it was pulled from the network in 2015 following revelations that Duggar had molested four of his sisters and a babysitter. Duggar’s parents said he had confessed to the fondling and apologized.

Duggar previously apologized for a pornography addiction and cheating on his wife.

Federal prosecutors cited Duggar's admitted molestation as a sign that he was a danger to the community.

"He has shown the court he has a history dating back 20 years that shows a sexual attraction to children and the deviousness of his activity," Assistant U.S. Attorney Carly Marshall said.

Comstock said that, during his release, Duggar could have contact with his children only with his wife present. But the judge said Duggar could not be around any other minors, including other family members.

JOSH DUGGAR GRANTED RELEASE FROM JAIL AS HE AWAITS TRIAL IN FEDERAL CHILD PORNOGRAPHY CASE

Federal authorities said they began investigating after a Little Rock police detective found child pornography files were being shared by a computer investigators traced to Duggar. A federal Homeland Security agent testified pornographic images depicting the sexual abuse of children, including toddlers, had been downloaded in May 2019 by a computer at a car dealership Duggar owned.

Josh is the eldest son of TLC stars Jim Bob and Michelle Duggar. 

Josh is the eldest son of TLC stars Jim Bob and Michelle Duggar.  (Washington County Police Department/Getty Images)

Agent Gerald Faulkner said multiple child pornography files were found on the computer and that more than 200 images had been found on the computer that had been deleted.

Faulkner said the images downloaded were among "top five of the worst of the worst that I've ever had to examine."

A monitoring program that sent reports to Duggar’s wife about his activity had been installed on the computer, but the images and videos were downloaded after software had been installed that allowed him to download them without being monitored, Faulkner said.

CLICK HERE TO GET THE FOX NEWS APP

Duggar's attorneys had argued that he wasn't a danger to the community and has not tried to flee since authorities began their investigation two years ago.

"He has not left the jurisdiction, he has not left the country, he has not done anything at all other than continue to live his life in this judicial district where he has deep roots," Justin Gelfand, an attorney for Duggar said.

The Associated Press contributed to this report.