As the Trump administration’s massive deportation campaign unfolded, tens of thousands of immigrants were swept up in enforcement actions and placed in Immigration and Customs Enforcement detention facilities across the nation. In addition to unauthorized immigrants and visa overstayers, that population included people whom immigration judges had granted withholding of removal or protection under the Convention Against Torture.

These protections bar the government from deporting a person to a specific place—usually their home country—because they are likely to face further persecution or torture there. Unlike asylum, however, the protections are granted alongside an order of removal. 

That order generally directs ICE to detain the person and spend up to 90 days attempting to remove them. If the person has withholding of removal or CAT protection, the government cannot send them to the country from which they are protected. Instead, ICE may try to find a third country willing to accept them, as long as the person does not have a credible fear of persecution there, too. 

When someone remains detained beyond that 90-day period, or is redetained after it has passed, those with the means can file a habeas corpus petition. These petitions ask a federal judge to review whether the government has a legal basis for continuing to hold the person.

Quantifying and contextualizing such cases, however, requires a detailed review of individual court records. That’s become more challenging as the number of detainees has inundated detention centers and overloaded the immigration legal system. AZCIR had to piece together information from multiple sources and make informed decisions about what to include. 

Here’s a closer look at our approach. Click the questions below to jump to a section, or scroll down to read the full methodology.


How did you collect and filter the data?
How did you account for cases that weren’t captured in the initial search?
How did you decide which cases to use?
How did you determine the timeframe for the analysis?
How did you calculate time in detention?
How did you determine when someone was released?


How did you collect and filter the data? 

We relied on three key sources: a volunteer-run digital database of habeas corpus filings, ProPublica’s national habeas case tracker and records from Arizona’s federal courthouse, which we reviewed to identify cases not previously released publicly. We also used a spreadsheet created by a federal public defender to confirm case grounds and outcomes, largely for additional information and verification rather than as part of the analysis itself.

The initial skeleton of our database came from the Habeas Dockets website, created by John Kyle Cronan in 2025 to broaden public access to federal habeas corpus case documents. The volunteer-run website aims to track cases in near-real time. 

Through the website, AZCIR was able to review roughly 1,000 text files, each of which contained at least the docket—or case history log—for the habeas proceeding. But because of the unprecedented increase in habeas cases nationwide, as well as efforts by Cronan’s team to redact sensitive information, the files were not always comprehensive. 

AZCIR first used R to filter the files for petitions that mentioned “withholding of removal” or “convention against torture.” That left us with 88 petitions. We then used Python and one of Anthropic’s large language models, Claude Haiku 4.5, to extract structured data from those cases. We manually reviewed and validated each entry.

About half of the original 88 cases met our criteria and were included in our final analysis.

How did you account for cases that weren’t captured in the initial search?

Our initial approach would have missed cases in which a person had one of the protections but the available file contained only the case docket and not the underlying petition, as the relevant key words would not have appeared in the documents we searched. To account for those instances, we created a dataset of all known cases from our text files, joined it with our database of the 88 cases, and isolated the ones that had no entry under the “protections” category. 

When we expanded the scope of our analysis to include cases filed from January-March 2026, we used a similar process to extract structured data through Claude. This time, we asked the model to indicate whether a file contained only a docket and no corresponding case documents. This allowed us to quickly see which cases we would need to review at the courthouse.

As a secondary check, we compared our raw case count against ProPublica’s database.

After completing this process, we had 774 cases that contained only a docket or a case number to look up. We referenced those files in person at Arizona’s federal courthouse and reviewed each by hand.

When we found a case that fit our criteria, we printed the relevant pages for reference during AZCIR’s fact-checking process.

How did you decide which cases to use?

Of the 1,000-plus habeas cases AZCIR reviewed, we identified around 120 that met our criteria: cases involving people with an order of removal who had been granted either withholding of removal under the Immigration and Nationality Act or some form of protection under the Convention Against Torture. 

Around 10 petitioners, however, had an unclear order-of-removal date. That date mattered because it helped us calculate how long someone had spent in detention following an order of removal. We therefore included this group in the total count of petitioners granted such protections but excluded them from our time-in-detention analysis.

How did you determine the timeframe for the analysis?

Our analysis began with 2025, the first and only full year of cases tracked by Habeas Dockets. We then expanded the analysis to include the first three months of 2026 to see whether the increase in habeas cases continued.

We used ProPublica’s data to validate what we had heard from immigration lawyers—that the influx of habeas petitions was unique to the second Trump administration. While there were smaller spikes in habeas filings in years outside the current administration, they didn’t reach the levels observed in 2025 and the first part of 2026. That includes the first Trump administration.

How did you calculate time in detention?

A core component of this project involved determining how long petitioners spent in detention despite receiving court-ordered protection. 

We focused on four dates: the date of detention, the date of the final removal order, the date of a judge’s ruling and the date of the petitioner’s release.

If someone was granted either protection while in detention, we used the date of the final order of removal as the starting point. In cases where it was unclear whether the removal order became final on the same date it was issued, we added 30 days, excluding federal holidays, to the date of issuance. That accounted for the possibility that a removal order may take up to 30 days to become final when a party reserves the right to appeal but does not ultimately file one. We used this conservative approach to avoid overstating the amount of time someone spent in detention after receiving a final order.

If a person had a final order of removal but its issue date was unclear, we left it out of our average calculation.

How did you determine when someone was released?

Finding the end date of someone’s detention was more complicated. In the best of cases, a judge ordered the government to file a notice of compliance. Those notices usually contained the date the petitioner was released. However, there were occasions when a notice did not include a release date, the judge did not order a notice of compliance, or the judge ordered one but the government never filed it. 

When a notice of compliance indicated that a petitioner had been released either the day the judge issued the order or the following day, we used the date of the order when no release date was available.

If a petitioner was deported before the judge’s ruling, we used the date of their deportation.

In a small number of cases, a petitioner did not win their habeas case or a subsequent case, and we could not locate them using their A-number and country of origin through the online detainee locator system. We therefore could not confirm whether they remained detained or determine when they may have been released or deported. We excluded those cases from the time-in-detention calculation.

Creative Commons License

Adriana Navarro is an investigative reporter at AZCIR covering the intersection of gender, politics and policy.