San Francisco officials on Friday advanced a bill that would halt the sale of e-cigarettes in the city — setting up the measure to get a vote by the full Board of Supervisors on June 18.

The city’s Public Safety and Neighborhood Services Committee voted 3-0 to recommend that the legislation go before the full board for approval.

If the bill passes, it would suspend the sale of e-cigarettes at brick-and-mortar stores and prohibit the delivery of e-cigarettes bought online to San Francisco addresses until the U.S. Food and Drug Administration completes a review to ensure the safety of e-cigarettes.

If it is approved, San Francisco would become the first U.S. city to prohibit the sale of e-cigarettes, though the prohibition might not be permanent: E-cigarette companies face a 2021 deadline to submit applications for FDA review.

The measure was authored by City Attorney Dennis Herrera and Supervisor Shamann Walton, who are aiming to curb rising youth vaping rates. The phenomenon, partly driven by the wildly popular Juul vaping device and nicotine pods, is worrying many parents and public health experts about the potential long-term harm nicotine addiction could have on teens.

Juul, the industry leader with 80 percent of the e-cigarette market, has already taken steps to circumvent the ban if it passes. The company is sponsoring a ballot measure for November’s election that would override the city’s ban, if it passes.

San Francisco already prohibits the sale of flavored tobacco products, such as the fruit- and dessert-flavored nicotine pods made by Juul that are popular among teens. City voters approved those restrictions through Proposition E in 2018 and they went into effect this year.

The committee hearing drew hundreds of San Francisco residents, business groups, public health researchers and lobbyists for both Juul and the vaping industry, as well as for anti-tobacco advocacy groups. For nearly three hours, they lined up to implore the committee’s members — Supervisors Rafael Mandelman, Walton and Catherine Stefani — to embrace the ban or shoot it down.

The turnout and impassioned testimonies spoke to the controversial and polarizing nature of e-cigarettes. It pitted medical experts, parents and anti-tobacco advocates against vaping industry interests — and raised questions about personal freedom and choice.

Stanton Glantz, director of UCSF’s Center for Tobacco Control Research and Education, called the bill “one of the smartest local laws I’ve seen in a long time.”

Glantz and UCSF associate professor Jeremiah Mock, a longtime tobacco researcher, endorsed the measure, as did San Francisco Health Officer Tomas Aragon and the American Heart Association.

“San Francisco has the opportunity to protect the youth of this community by supporting this ordinance and send the message to the e-cigarette companies: the city is done paying your reparations, it’s time to wave the white flag and keep your products out of our city and out of the hands of our youth,” said Audrey Abadilla of the San Francisco Tobacco Free Coalition.

But many adult former cigarette smokers, while acknowledging concerns about teen vaping, oppose the legislation because they say switching to e-cigarettes improved their health. They urged the city to regulate the products to keep them away from children while preserving access for adults over 21 who can legally buy tobacco products, rather than impose an outright prohibition.

“Vaping has been a savior for me,” said Judy Smith, a former teacher and longtime two-packs-a-day cigarette smoker who said she was able to quit cigarettes after switching to vaping. “The proposed ban is not a good idea. Bans work in our heads. They don’t work in reality. Forbidden fruit is always more exciting.”

Dozens of owners of corner stores and vape shops said the proposed e-cigarette ban would hurt their business. Many sell vape products exclusively, and even smoke shops that also sell conventional cigarettes say they would lose hundreds of dollars in sales each day if they could no longer sell e-cigarettes.

To address the concerns, Walton said he will work with Supervisor Sandra Lee Fewer to create a working group to explore alternative revenue streams.

“This is not an attack on our small businesses but it is an attack on harmful products,” Walton said. “I do hear your concerns.”

Catherine Ho is a San Francisco Chronicle staff writer. Email: cho@sfchronicle.com Twitter: @Cat_Ho