PHILADELPHIA—During the 15 months that Allen Woods has been held, awaiting trial, at a federal detention center downtown, he has only seen his six-year-old son once. This has been hard on them both, as they used to spend time together almost every day. Woods would pick his son up from school, take him to T-ball practice—all the things that an involved parent does.

“A child that was raised with both parents and one is suddenly taken away—he is going to be confused,” the boy’s mother, Chamira Williams, told me. “He has been depressed, confrontational, not understanding why he can’t see his father. It’s hard.”

The detention center is the federal version of the local county jail; most inmates there haven’t been convicted of a crime, while a small minority is serving short sentences. The center’s rules, which appear to be the most restrictive in the country, prohibit any inmate awaiting trial from having a visitor who is not an immediate family member; only a parent, step-parent, foster parent, sibling, child, or legal spouse qualifies. That means that Williams, Woods’s ex-girlfriend, is barred. And without relatives willing or able to accompany her son on a visit, the restrictions effectively block him, too. “I should have the option to take him to see his father,” Williams said.   

In theory, the impact of this policy would be minimal, as it applies only to the pretrial period. But in reality it can take months or years for a case to make its way through the court system—delays brought on and exacerbated by public-defender shortages and case backlogs. Woods faces charges of possession of large amounts of marijuana with the intent to distribute. Ironically, when he is finally sentenced—and no matter the verdict—he will have a much easier time seeing his son.

Woods is one of two named plaintiffs in a federal class-action lawsuit filed last week against the detention center’s warden, which alleges that the visitation policy makes it “impossible or unreasonably difficult for many pretrial inmates to see their minor children while in custody.” It estimates that, out of the roughly 900 pretrial inmates, there are more than 100 whose children have a tough time visiting—whether those kids are with a romantic partner they aren’t married to, with an ex-girlfriend or -boyfriend, or with an ex-spouse. Woods’s attorney, Dana Bazelon, told me that prior to the policy change in July 2016, the visiting room would be “packed” any time she went to see a client, but “now it’s a different world in there—there are just not as many visitors.”

The lawsuit argues that the policy infringes upon the inmates’ constitutional rights—to freedom of association, against cruel and unusual punishment, and against unequal treatment without a rational basis. The suit also claims the rule is at odds with a Federal Bureau of Prisons directive that “encourages visiting by family, friends, and community groups to maintain the morale of the inmate.” Bazelon found no rule so restrictive when she surveyed other federal detention centers; they all allowed at least some visitation from non-family members. At the state level, the Mississippi Department of Corrections tried limiting visitors to its facilities to immediate family last year, citing security concerns. But the short-lived policy was postponed indefinitely following a rebuke from family members and prisoner advocates.

There are two exceptions to the Philadelphia center’s rule: one for inmates who have no living immediate family members, and another for inmates who can show a demonstrable need, including seeing a child whose other parent is not their legal spouse, Michael Carroll, the detention center’s public-information officer, wrote in an email. Those exceptions, however, can be difficult to secure. Bazelon has helped 10 or so clients apply for one, but all were denied.

The reasons varied. One inmate, for example, was rejected because he’s not listed on his son’s birth certificate. To change that, he would need to submit a notarized form to the state, but having a notary visit the prison would cost him $150—money he doesn’t have. Another could not track down the death certificate of his estranged father in order to prove he had no living family. And another asked that his ex-girlfriend be allowed to bring their child because his immediate family would not, due to a conflict. The warden’s rejection letter simply restated the center’s policy on visitors, and didn’t explain why he didn’t qualify for an exception.

Asked about the policy’s impetus, Carroll told me that restricting visitors “was necessary to enhance the safety and security of the institution.” He specifically cited an “increase in the amount of illegal drugs entering the facility through the visiting room.” Carroll did not respond to request for further comment—on the severity of the increase, any additional security steps taken, or how long the policy will stay in place. Without those answers, it’s difficult to assess officials’ plans. Bazelon, for her part, told me “the security issues that they raised could be addressed with fairly easy security measures or steps that don’t involve restricting access to kids”—like more guards in the visiting room or increased video surveillance.

That’s more or less how New York City’s Riker’s Island, the country’s largest pretrial lockup, has handled its own contraband problem. In 2015, administrators brought in more drug-sniffing dogs, installed machines to detect hidden cellphones, and launched an “amnesty program” wherein visitors are allowed—and encouraged—to hand over illicit items without risk of punishment. With these measures in place, guards seized drugs from 45 percent more visitors the following year. All along, inmates could be seen by both friends and family.

More forgiving policies reflect years of academic research, which suggest that maintaining close ties with loved ones provides emotional relief for inmates and helps with their transition back into their communities after release. Fewer studies, however, have evaluated how contact with an incarcerated parent helps children deal with the stress of their absence. In a 2015 study from Child Trends, a nonpartisan childhood-research nonprofit, the authors explained that the loss of an “attachment figure,” the psychological term for an adult with whom a child is emotionally bonded, can be potentially—and unsurprisingly—traumatic. “One thing that policymakers can do is make it easier for children to maintain positive relationships with their parents during the period of incarceration,” the authors wrote.

Woods is awaiting his trial date at the end of this month. Williams continues to struggle with helping her son cope, and he still asks frequently when he can visit Woods. “Children should have the option to see their parents no matter what the situation is,” she said. “Whatever reason he is in there, that has nothing to do with family.”