A plan to provide some New York City homeowners credits on their water bills while hiking rates for other users was arbitrary, a state appeals court ruled.

The ruling, issued Thursday by a 3-1 panel of the Appellate Division, First Department, affirmed Manhattan Supreme Court Justice Carol Edmead’s order to invalidate the city Water Board’s vote to provide one-time $183 credits to one-, two- and three-family residences—regardless of property value or size—while implementing a 2.1 percent increase for other users.

In April 2016, Mayor Bill de Blasio announced the credit plan, saying it would be funded by waiving $122 million in rental payments charged to the Water Board and that it would benefit 664,000 homeowners, or about 80 percent of all water and sewer customers.

The board also discussed using the rate increase on other users to cover a $76 million budget shortfall.

In an unsigned decision, Justices David Friedman, Karla Moskowitz and Judith Gische of the First Department said they agreed with Edmead’s finding in Prometheus Realty v. New York City Water Board, 653003/2016, that there is no rational basis to provide a credit to some customers while raising rates on others to fill a budget deficit.

In dissent, Justice Marcy Kahn said the board acted within its authority.

Herrick Feinstein partners Michael Berengarten and Kevin Fullington and associate Jared Newman represented the plaintiffs, which included property owners and the Rent Stabilization Association, a landlord advocacy group.

“The proposal, in and of itself, was inequitable,” Berengarten said in an interview.

Assistant Corporation Counsel Michael Pastor appeared for the city. In a statement issued on Thursday, de Blasio said the city would “continue to fight” to provide the credit.