ALAMEDA — Renters in Alameda secured a victory early Wednesday morning when the City Council voted to protect them from unjustified evictions.

The move came after the council heard from renters who said they fear that they could be put out of their homes at any time amid the Bay Area’s hot real estate market, and from property owners who said they were being treated unfairly and that their rental business could be undermined.

“We are not trying to punish anyone,” said Councilman Jim Oddie, who noted that Union City and San Jose also recently made landlords cite reasons before evicting tenants. “I think what we are trying to do is protect people.”

The vote to amend the city’s rent stabilization ordinance to include “just cause” protections for tenants as a way to prevent landlords from evicting someone without a specific reason, was 3-2.

Along with Oddie, Vice Mayor Malia Vella and Councilwoman Marilyn Ezzy Ashcraft supported the change. Mayor Trish Spencer and Councilman Frank Matarrese voted no, citing reports that the step could prompt some landlords to remove units from the market.

The council adopted the rent ordinance in March 2016 after weeks of emotional debate that pitted property owners and tenants against each other.

The ordinance does not limit the amount that a landlord can raise rent. But it does require a landlord to notify the city’s Rent Review Advisory Committee, which mediates disputes between tenants and landlords, if the rent will increase more than 5 percent.

The council adopted the “just cause” provision on Wednesday as part of an annual review of the ordinance, which aims to provide renters with stability over concerns that they could be displaced because of the Bay Area’s high housing costs.

“I don’t think you are going to find anything better,” property owner Lester Cabral said about the ordinance.

He urged the council not to tinker with the ordinance because Alameda voters had supported it after the council put it on the ballot in November, when a tougher rent control measure was also an option.

“‘Just cause’ is not a fair trade between housing providers and tenants,” landlord Eunice Edwards said, “and it’s not good for the city’s living environment without being able to evict problem tenants.”

Local landlord Karen Bey said she financially struggled to purchase and maintain her rental property and wanted it so that she would have income when she retired.

“I feel like I am being punished,” Bey said. “And I am being punished because I bought income property.”

Maria Dominguez of the Alameda Renters Coalition said the council had declared Alameda a sanctuary city in response to the election of President Trump and his actions to crack down on illegal immigration.

But she said many renters feel the city does not offer a sanctuary for them “because being safe is having a roof over your home.”

Other speakers noted that renters are still facing steep rent increases and evictions, despite the stabilization ordinance.

Oddie said rental properties are not typical businesses because they are also people’s homes.

An unexpected eviction can “wreak havoc” on families who might have to pull their children out of school as they look for housing that they can afford away from Alameda, Ashcraft said.

“We want to protect or most vulnerable,” she said.

The rent stabilization ordinance will sunset in December 2019 unless the council votes to continue it.