Gov. Paul LePage is threatening to withhold all state funding for General Assistance from communities that ignore his administration’s new policy prohibiting undocumented immigrants from receiving aid.

In a letter sent Monday to municipal officials statewide, the governor wrote, “I expect the head of each municipality to communicate with (the Department of Health and Human Services) to certify in writing compliance with federal law. … If DHHS finds that a municipality fails to comply with the law, it will cut off all General Assistance reimbursement to that community.”

LePage’s letter follows guidance issued this month by the DHHS, which said the state will no longer reimburse municipalities for General Assistance they give to undocumented immigrants. It raises the financial stakes for Portland and other communities that have argued that current law requires them to provide General Assistance to the needy residents regardless of immigration status.

Opposition from officials in Portland indicates that the issue could be headed to court. Maine’s largest city received $7.4 million from the state last year for all General Assistance recipients. The money helped support nearly 4,300 people, the vast majority of whom are legal U.S. citizens.

Portland Mayor Michael Brennan said he was “astonished” that LePage would withhold reimbursements to cities and towns that merely follow state law.

“It’s just not fair to be putting municipalities in this position for his own political gain and then to cause this type of uncertainty and angst for hundreds of Portland residents,” said Brennan, a former Democratic state lawmaker. “The governor of the state should be acting with more discretion.”

Portland and Lewiston stand to be disproportionately affected by the policy shift because of their sizable numbers of asylum seekers. Portland provided $250,000 in assistance in May to about 600 people who likely would be classified as undocumented immigrants.

That population is largely composed of people who are seeking asylum from persecution in their home countries and are prohibited from even applying for federal work permits for 150 days after they file for asylum.

While Brennan said he doesn’t believe that LePage can carry out his plan, he said city officials will talk to Attorney General Janet Mills and Portland’s legal team about pre-emptively challenging the policy in court.

The American Civil Liberties Union of Maine has pledged to fight the policy shift.

A report in September by the Congressional Research Service, the nonpartisan office that provides policy and legal analysis to Congress, said courts have ruled on both sides in considering the constitutionality of states’ attempts to limit public benefits to non-citizens.

Maine now reimburses municipalities for 50 percent to 90 percent of their General Assistance expenditures to help individuals and families pay for basic needs such as housing, food and heat.

In his letter, the Republican governor said a 1996 welfare-reform law prohibits states from offering General Assistance to undocumented immigrants unless they pass laws specifically allowing it.

The administration says Maine has no such laws, and the governor wrote in his letter that he “found it inexplicable that the state’s top law enforcement official would encourage municipalities to violate federal law.”

LePage has clashed publicly with Attorney General Mills, a Democrat, who has raised questions about the constitutionality of the administration’s earlier attempts to prohibit General Assistance funds from going to refugees, asylum seekers and undocumented immigrants.

LePage focused on the issue in his weekly radio address, a text of which he released Tuesday. He says in the address, “I urge all Mainers to tell your city councilors and selectmen to stop handing out your money to illegals.”

The Maine Municipal Association has advised communities to continue offering assistance to undocumented immigrants until the program’s eligibility requirements are changed through legislation or the rule-making process. Current eligibility requirements do not address immigration status.

Geoff Herman, who handles state and federal policy for the association, said Tuesday that the DHHS guidance earlier this month indicated that the state would withhold only its reimbursement for General Assistance provided to undocumented immigrants. So the governor’s letter conflicts with his own department’s guidance, Herman said.

“These sorts of missives, these edicts and these handed-down guidance documents aren’t the way a program should be administered,” Herman said.

Lewiston City Administrator Ed Barrett said city councilors are awaiting additional legal and policy guidance before deciding how to proceed on the new policy. For the time being, the city will continue offering assistance to applicants regardless of their immigration status.

Barrett said LePage’s threat to withhold all state reimbursement is “clearly a major change from what we were told in the original DHHS guidance.”

Lewiston paid about $1 million in General Assistance last year and was reimbursed by the state for nearly two-thirds of that total, so losing state funding “would be a significant hit,” he said.

Like Portland, Bangor and South Portland have said they plan to continue providing public benefits to undocumented citizens despite the DHHS guidance. Westbrook is considering whether it can afford to use city funds alone to keep providing assistance to about a dozen families, and has asked the state to clarify whether those families are eligible.