NEW YORK — Nursing homes are increasingly evicting their most challenging residents, testing protections for some of society’s most vulnerable, advocates for the aged and disabled say.

Those targeted for eviction are frequently poor and suffering from dementia, with families unsure of what to do, according to residents’ allies. Removing them allows an often stretched-thin staff to avoid the demands of labor-intensive patients in favor of ones who are easier and more profitable.

“When they get tired of caring for the resident, they kick the resident out,” said Richard Mollot of the Long Term Care Community Coalition, a New York advocacy group.

Complaints and lawsuits across the U.S. point to a spike in evictions even as observers note available records only give a glimpse of the problem.

An Associated Press analysis of federal data from the Long-Term Care Ombudsman Program finds complaints about discharges and evictions are up about 57 percent since 2000. It was the top-reported grievance in 2014, with 11,331 such issues logged by ombudsmen, who work to resolve problems faced by residents of nursing homes, assisted living facilities and other adult-care settings.

The American Health Care Association, which represents nursing homes, defends the discharge process as lawful and necessary to remove residents who can’t be kept safe or who endanger the safety of others, and says processes are in place to ensure evictions aren’t done improperly. Dr. David Gifford, a senior vice president with the group, said a national policy discussion is necessary because there are a growing number of individuals with complex, difficult-to-manage cases who outpace the current model of what a nursing home offers.

“There are times these individuals can’t be managed or they require so much staff attention to manage them that the other residents are endangered,” he said.

The numbers of both nursing homes and residents in the U.S. have decreased in recent years; about 1.4 million people occupy about 15,600 homes now. The overall number of complaints across a spectrum of issues has fallen in the past decade, though complaints about evictions are down only slightly from their high-water mark in 2007, the federal figures show. Meanwhile, the share of complaints that evictions and discharges represent has steadily grown, holding the top spot since 2010.

Advocates say offending facilities routinely flout federal law, attempting to exploit and widen justifications for discharge. They say hospitalizations are a common time when facilities seek to purge residents, even though the Nursing Home Reform Act of 1987 guarantees Medicaid recipients’ beds must be held in their nursing homes during hospital stays of up to a week.

Whatever a facility’s reasons are, involuntary discharges leave families reeling.

When John Wilson, 61, was refused readmission to St. John’s Pleasant Valley, a nursing home in Camarillo, California, the facility cited his family’s repeated complaints about his care, his son Jeremy Wilson said.

The family sued to get Wilson back into the nursing home, but even when they prevailed, the facility refused. The younger Wilson said his father, who has Lou Gehrig’s disease and is unable to speak or walk, was needlessly kept hospitalized for more than seven months until management changed and the home finally relented.

“What they look for and what they want is basically the family to drop Grandpa off at the front door and not be involved,” he said. “They don’t want anybody monitoring them, they don’t want anybody complaining. They just want to take care of that person until they die and collect that check.”

Dignity Health, the facility’s parent company, said it could not discuss the specifics of the case but that patient care and safety are the top priority.

Federal law allows unrequested transfers of residents for a handful of reasons: the facility’s closure; failure to pay; risk posed to the health and safety of others; improvement in the resident’s condition to the point of no longer needing the home’s services; or because the facility can no longer meet the person’s needs.

Though that final category is often cited in evictions, advocates dispute how often it fits.

“The majority of the time, it’s because the resident is considered difficult,” said Tony Chicotel, an attorney for California Advocates for Nursing Home Reform.

Chicotel says involuntary discharges are almost entirely focused on Medicaid beneficiaries and that economics sometimes play a role in the ousters. Rather than a long-term Medicaid patient, many facilities would prefer to fill a bed with a private-pay resident or a short-term rehabilitation patient, whose care typically brings a far higher reimbursement rate under Medicare.

Whatever facilities’ reasons, the process can be harrowing.

“It’s not just losing their home. It’s losing their whole community, it’s losing their familiar caregivers, it’s losing their roommate, it’s losing the people they sit with and have meals with,” said Alison Hirschel, an attorney who directs the Michigan Elder Justice Initiative and has fought evictions. “It’s completely devastating.”

Agyemang Bediako knows the feeling well. After breaking both legs in a jump from a burning building, he found himself recovering at a New York City nursing home. He said he was still undergoing rehabilitation when the facility told him it would be discharging him to a homeless shelter.

“I was panicked,” he said, describing his thoughts before a successful appeal of his case. “What am I going to do? I couldn’t even eat. I became depressed. I wanted to kill myself.”