U.S. District Judge Dolly Gee ruled June 26 that U.S. Customs and Immigration Enforcement (ICE) must release at least 120 children held in detention with their families by mid-July. The nation’s family detention centers are “on fire,” Gee wrote in her order. “There is no more time for half measures.”

She’s right. More than 2,700 cases of COVID-19 have now been reported among the nation’s immigrant detainees, along with 45 more among ICE employees. Detainees describe a lack of access to basic hygiene products, like hand soap and disinfectant, even while they continue living in exceptionally tight quarters. Family detention facilities have seen their first cases.

Now the Trump administration and ICE will have to determine how to best comply with Gee’s order. And it’s clear that under the current circumstances, they must avoid separating families or keeping any family members in detention, where their health is at risk. Rapidly deporting detainees—and perhaps a deadly virus—to their countries of origin is also not an option, particularly given those countries’ limited health care infrastructure.

Instead, the administration must look toward alternatives to detention: releasing non-violent detainees, including children and families, so they can await their asylum hearings out of harm’s way. Alternatives to detention are the only path forward that will minimize health risks while avoiding separation of families.

We already know that alternatives to detention work.

Alternative methods ICE has used so far, including electronic monitoring, case management, parole, bond and check-ins, have proved highly effective. According to government analyses, more than 90 percent of participants in alternatives to detention programs comply with court orders and nearly 100 percent attend their immigration court dates. Participants in one promising pilot program ended by the Trump administration in 2017, the Family Case Management Program, demonstrated 99 percent compliance for check-ins with immigration officials and 100 percent compliance for their scheduled court hearings.

They are also far less expensive for U.S. taxpayers.

In 2018, ICE spent more than $200 per person per day to detain someone in an immigration detention facility. For those held in family detention—such as the children impacted by Gee’s recent order—costs can regularly exceed $300 per person per day. The average cost per person per day when alternatives to detention were used, in contrast, was about $5.

Perhaps most important, alternatives to detention are the humane way forward, especially as ICE detention facilities increasingly reveal themselves to be COVID-19 hot spots. Given the health risks to children in detention, releasing families with alternatives is the moral choice.

Aside from exposing immigrants to a deadly pandemic, detention can lead to long-term psychological damage and lasting trauma, particularly in children. One study found that 32 percent of children held at a detention center showed signs of emotional distress; 17 percent displayed symptoms of post-traumatic stress disorder.

And criminal justice researchers have found that children of incarcerated parents are, on average, six times more likely to become incarcerated themselves. Of course, the overwhelming evidence proves that immigrants commit far fewer crimes than native-born Americans. But policymakers should be aware: releasing children while leaving their parents detained could deprive those children of the relationships necessary to lead healthy, crime-free lives.

In the days ahead, the Trump administration will determine how best to comply with an order requiring the release of children in family detention. Only one option is compassionate—as well as incredibly effective and less expensive.

Alternatives to detention provide a clear path forward for our immigration system, both during this global pandemic and beyond.