About a year and a half ago, Victoria stopped eating. Her face was white. Her legs and stomach were swollen. She couldn’t get out of bed. (Victoria is a pseudonym; we’re not publishing her real name, because she’s an undocumented immigrant.)

Her brother took her to the emergency room, and she was hospitalized immediately. The doctors told her she had diabetes, high blood pressure, and anemia, and her kidneys had failed.

“That is, I was very, very sick,” Victoria said in an interview, in Spanish.

Victoria is 52 years old; she’s originally from Mexico, but she’s been living in Texas for more than 30 years. She’s a full-time caregiver for her 23-year-old daughter, who was born in the United States and is severely disabled. The two of them live on her daughter’s disability checks.

The day Victoria was hospitalized, she got a blood transfusion, blood pressure medications, and emergency dialysis. Dialysis is a medical procedure that uses a machine to do what working kidneys are supposed to do: filter the body’s blood, removing toxins and excess fluid. Diabetes, high blood pressure, autoimmune diseases, and genetic diseases can all cause a person’s kidneys to fail. That used to be an immediately life-threatening condition. But since dialysis was established as a regular treatment in 1960, patients with kidney failure can live five to 10 years or even longer with regular dialysis.

There are more than 660,000 people in the United States whose kidneys have stopped working. Of those, about 200,000 have a working kidney transplant. The rest are on dialysis.

If Victoria had been a US citizen, she would have been scheduled for regular dialysis. Three times a week, she would have gone to a clinic for four hours so a machine could clean her blood. Medicare would have paid for it; kidney disease is the only disease Medicare covers regardless of the patient’s age.

If she’d been a US citizen, she would also have been put on a transplant list—and, if she’d had a match, Medicaid would have paid for the transplant and all the anti-rejection drugs afterwards. People who get transplants live three to 15 years longer than those on dialysis, and transplants are less expensive than dialysis if the patient is likely to live more than two to three years.

But because Victoria is undocumented, there was no one to pay for regular dialysis or a transplant. Instead, after the doctors stabilized her, they sent her home.

Victoria came home from the hospital feeling okay. She had her appetite back and could get out of bed.

As the days went by, her symptoms got worse again. Her belly and legs started to fill with fluid; she says she couldn’t even button her pants, because her stomach was too swollen. Her breathing was so labored it was hard to speak.

Victoria says, whenever someone called her, “I gave the phone to my brother, because I could barely speak. I said hello and got short of breath.… I felt that I couldn’t breathe.”

Because Victoria’s kidneys weren’t working, fluid was filling her lungs, making her so short of breath she couldn’t speak a full sentence, and toxins were building up in her body, putting her at risk of heart failure.

She had to go back to the emergency room, where she was immediately put on oxygen.

There are about 6,500 undocumented immigrants with kidney failure living in the United States. What kind of treatment they get depends on where they live. Since 1986, the federal government has required that hospitals treat patients in the emergency room regardless of their immigration status or ability to pay, and Medicaid picks up the tab. In 43 states—including Texas, where Victoria lives—that means undocumented immigrants can get dialysis only when so many toxins build up in their blood that it’s an immediate, life-threatening emergency.

When Michael Gusmano, a health policy researcher at the Hastings Center and a professor at Rutgers University, started looking at access to care for undocumented immigrants in the United States, he found the situation for undocumented immigrants with kidney disease to be the most dire.

“One of the groups most troubled by [the status quo] are nephrologists”—kidney doctors—he says, “because they’re not able to treat [undocumented] patients the way they treat their other patients.… They feel as if they’re torturing people.”

Germán Hernández is one of those nephrologists. He works in El Paso, Texas, and has had to tell many undocumented immigrants that they can get dialysis only on an emergency basis.

“You’re basically telling them, ‘From now on, your life is going to be in and out of the emergency room every seven to 10 days, and you’re never really going to feel well,’” he says. “The body is going through all this disequilibrium back and forth that they just never feel well. It’s a terrible existence.”

Some patients, like Victoria, arrive at the emergency room short of breath and need to be put on oxygen right away, Hernández says.

Others “get so confused from all the toxins that are accumulating that that’s the reason why family members bring them in,” he says. Other times, swollen legs or a lack of appetite are their main symptoms.

In those cases, the hospital tests the patients’ potassium to see if the levels are high enough to qualify for emergency dialysis.

“What I’ll tell my patients is, ‘If you’re not sure, drink some orange juice in the emergency waiting room before you get your blood drawn, because that will raise your potassium levels,’” Hernández says.

When dialysis patients drink orange juice to get their potassium levels up, they risk heart failure.

“If your potassium level is too high, that can kill you,” Hernández explains.

But, Hernández says, it’s a necessary risk for these patients: They need dialysis. Hopefully, he says, if patients drink the orange juice in the emergency room, someone will be on hand to help if the patient’s heart stops beating.

When Victoria returned to the hospital, she got dialysis, spent the night at the hospital, got dialysis again, and then went home. It was a cycle: Every couple of weeks, she’d have to go back to the emergency room.

Hernández says that once patients are sick enough that they need emergency dialysis, it almost always requires at least two sessions, plus an overnight stay in the hospital, for them to be well enough to go home.

Advocates of the emergency-only system say providing regularly scheduled dialysis for undocumented immigrants would encourage people with kidney failure to come to the US for treatment, and that providing transplants for this population would take organs from citizens and legal immigrants.

But Rajeev Raghavan, a nephrologist in Houston, says only 3 percent of undocumented immigrants with kidney failure knew they had kidney disease when they arrived.

And Dr. David Ansell, an advocate for providing transplants, says 75 percent of undocumented immigrants have a family member who’s willing and able to donate—a much higher rate than the rest of the population.

Gusmano, the health policy researcher, says one of the main arguments for providing regularly scheduled dialysis or transplants is that it’s cheaper. Researchers in Houston calculated that emergency dialysis costs about four times as much as standard care: $285,000 per year instead of $77,000. Transplants are even more cost-effective; they pay for themselves in about two years.

Gusmano adds that emergency-only dialysis also takes patients out of the workforce: In one study, 35 of 44 undocumented kidney patients reported losing their jobs because they spent so much time either in the hospital or very sick.

Caring for patients on an emergency basis also significantly lowers their life expectancy.

Seven states—Arizona, California, New York, Washington, North Carolina, Illinois, and Colorado—have looked at these arguments and decided to define kidney failure as a “permanent emergency” covered by Medicaid, allowing all patients to qualify for regular dialysis, paid for by state taxpayers.

Illinois went one step further and, in 2014, passed a law to pay for transplants for undocumented immigrants. The law was never funded, but a nonprofit stepped in and offered to pay insurance premiums for qualifying immigrants in need of a transplant. Since then, more than 200 undocumented immigrants have joined transplant wait lists in the state.

“It’s a simple matter of ethics and fairness,” says Ansell, the Illinois doctor who advocates for providing transplants to undocumented immigrants. “If you’re undocumented in Illinois, you can get a driver’s license, and disproportionately the Latino community is signing up to donate their organs.”

In other countries with large undocumented populations, policies around treatment for kidney disease vary. Germany, Italy, and Canada provide regularly-scheduled dialysis. France and the UK do not. The UK does offer kidney transplants if the organ is not allocated to a citizen. Germany offers transplants after a two-year waiting period.

Ansell hopes other states will follow in Illinois’s footsteps and create a backdoor way for undocumented immigrants to receive transplants—but what he really wants is a national policy that would provide regular health care for undocumented immigrants, much like New York City’s new plan, which will be rolled out across the city by 2021.

As for Victoria, her doctor recently worked out a way for her to get health insurance and therefore start receiving regularly scheduled dialysis, so she’s doing much better—but what she really wants is a kidney transplant.

“I want to keep living, to be able to take care of my daughter,” she said. “That’s why I would like a transplant.”