The Seattle City Council unanimously approved a controversial new tax last night to charge the city’s largest business per worker in order to tackle homelessness and a housing crisis.

Under the new tax plan, businesses such as Amazon and Starbucks will be charged around $275 per full-time worker, per year. It will apply to the 500 or so companies in Seattle that gross at least $20 million a year. Healthcare companies will be exempt, as are non-profits.

The tax is expected to begin in 2019, and will raise around $48 million per year. Around 60% of this revenue will go to housing projects for low income residents. The rest will go to homeless services, such as shelters.

The tax has been subject to much debate. Private-sector critics, led by the e-commerce giant Amazon, have argued that the tax will drive businesses away from the city.

Unions have also protested the tax, claiming that it will hurt jobs.

Amazon announced earlier this month that it was freezing expansion plans in Seattle, pending the city’s decision on the tax, although it has now started them again.

Advocates of the tax say that Seattle’s homelessness problem has been exacerbated by soaring house and rent prices, which is in part due to its rapid economic growth and the proliferation of tech companies.

Seattle has the third biggest homeless population in the US, after New York and Los Angeles.

Meanwhile, median home prices in the city have risen to $820,000, while more than 41% of renters spend at least 30% of their income on housing.

The council yesterday voted 9-0 in favour of the tax, although the agreed-upon amount of $275 per worker is significantly less than the $500 originally proposed. The approved version of the tax also includes a five-year sunset clause, with an option to then reconsider the policy.

The watered-down tax will give Amazon a yearly bill of $12.4 million, down from around $20 million, for its 45,000 employees in the Seattle area. Other companies affected include Google, and Nordstrom.