The popular home-sharing website Airbnb is heading to federal court Thursday to wage a legal battle against its hometown of San Francisco. The preliminary injunction hearing is part of a lawsuit filed by Airbnb in June that aims to block a new San Francisco ordinance that would force home-sharing websites, like Airbnb, to remove illegal rentals that are not registered with the city. Under the new law, the city would be able to issue hefty fines to home-sharing companies if they do not remove unregistered listings.

HOSTING REQUIREMENTS IN SAN FRANCISCO INCLUDE:

Register as a business with the city of San Francisco

Sign up for an in person appointment with the Office of Short Term Rentals (1-2 day wait)

You will need a Business Registration Certificate, valid ID, proof of liability insurance

Fill out a registration application ($50 fee)

Average 3-week wait to have your application approved

San Francisco Supervisor David Campos believes the city is facing a housing crisis with rent prices skyrocketing across the city. Campos says sites like Airbnb may contribute to the decline of affordable housing and wants home sharing websites to take responsibility for their thousands of unregistered users.

“It doesn't matter [if] you are a small business or a $25 billion company like Airbnb, you have to play by the rules,” Campos told NBC Bay Area. “That's really what this is ultimately about, and that's why San Francisco is not going to be intimidated by what is essentially a bully tactic on the part of this company.”

Since February 2015, anyone in San Francisco wanting to rent out their home for less than 30 days is required to apply for a $50 permit from the Office of Short Term Rentals every two years.

But an NBC Bay Area Investigation in May found that hosts largely ignored the registration process. According to figures from Airbnb and the Office of Short Term Rentals, at least 82 percent of hosts failed to register with the city.

“Folks have been robbing people of that housing, and Airbnb has been driving the getaway car, and enough is enough,” said Campos during a San Francisco supervisors meeting back in June.

After NBC Bay Area’s Investigation, Campos and other members of the Board of Supervisors approved a new law that would allow the city to charge home-sharing companies up to a thousand dollars per day if they allowed unregistered users to continue to post their rentals online.

Airbnb fought back, slapping the city with an 18-page lawsuit that accused San Francisco of violating the company’s First Amendment rights of commercial speech. Airbnb also argued it would be a “significant burden” to verify whether all of its users are registered with the city.

Click Here to View Full Lawsuit

The new penalties were set to take effect in July, but San Francisco put enforcement on hold pending Airbnb’s lawsuit.

David Owen heads policy strategy for Airbnb and says the city’s registration process for hosts is impractical and too complicated for all users to comply.

“This is a new activity, it's a new economy and the city can and should be able to develop a simpler much more innovative process to enable folks to rent out their home for a few nights out of the year without going through a process that takes six, eight weeks,” Owen said. “[The process] requires endless amounts of paperwork, endless amounts of interaction with a mounting list of new city agencies that seems to grow almost by the month.”

While Airbnb is asking for a preliminary injunction to stall the city’s new law, it is unclear whether the judge will take several days to rule on the issue or potentially announce a decision during Thursday’s hearing.

Meanwhile, the $50 registration fee for renters is expected to increase to $250 in November to cover the costs of operating the Office of Short Term Rentals. Last year, taxpayers had to shell out $413,004 to keep the program going, according to an analysis by the San Francisco Controller’s Office.

Owen said Airbnb would like to work with the city to revise its registration process; while Supervisor Campos wants the company to respect city law.

“At the crux of the housing crisis is this question of will San Francisco continue to have a middle class,” Campos said. “If the court rules against the city and basically says you city government have no way of protecting the housing stock, the answer could very well be … there will be no middle class in San Francisco.”

______________________________________

Watch the entire series in this NBC Bay Area investigation: