Smoking either tobacco or electronic cigarettes will be prohibited inside apartments, condominiums and townhomes in unincorporated areas of San Mateo County under a ban approved 4-1 Tuesday by the Board of Supervisors.

Supervisors Carole Groom and Adrienne Tissier pushed the ordinance, which outlaws smoking inside and around multiple-unit buildings with one or more shared ceilings, floors, walls or ventilation systems. The ordinance also applies to any such buildings owned or leased by the county, regardless of where they are located.

Second-hand smoke that wafts between rooms poses a danger to other occupants in the same building, according to county health officials.

“We have a responsibility as a county to protect the health of our residents,” Tissier said.

Supervisor Don Horsley cast the dissenting vote, echoing the objection expressed by the San Mateo County Association of Realtors that condominiums shouldn’t fall under the ordinance because they are individually owned, not rented.

“Imagine telling someone, a buyer who paid $862,000 for a townhome … that they are now prohibited from smoking in their own home,” said Paul Stewart, government affairs director for the Realtors group.

Cigarette smoke would still affect non-smokers, Tissier countered.

“I just have a problem with banning the use of a legal substance in one’s own house,” Horsley said.

The law primarily will apply to North Fair Oaks and unincorporated areas of Redwood City, where 105 of the 134 multi-unit facilities with four or more units are located. The county is still tallying the number of two- and three-unit buildings that would be impacted, according to a memo by Groom and Tissier for Tuesday’s meeting.

Although the ordinance will take effect in new housing units 30 days after it is formally adopted, existing facilities won’t be hit for another 14 months.

In addition to banning smoking inside buildings with shared spaces, the ordinance prohibits it within 30 feet of building complexes, including decks, patios and other common areas. Motels, hotels, detached single-family homes and in-law units aren’t affected.

Medical marijuana is exempted under the ordinance.

To comply with the law, landlords must post “no smoking” signs in prohibited areas and establish any designated smoking areas at least 30 feet from any door, window or vent.

Rhovy Lyn Atonio, a government affairs director for the local division of the California Apartment Association, said the ordinance it helped shape is “reasonable.” A provision that spares landlords from liability if a tenant smokes as long as they follow the ordinance’s requirements makes it “one we can support,” she said.

Enforcement of the ordinance will largely be complaint-driven. Smokers who violate the ordinance could be fined up to $100 for the first infraction, up to $200 for the second and up to $500 for each additional offense within a year. After three violations, the next one would be charged as a misdemeanor. Each day a person violates the law would be considered a separate violation.

San Mateo County’s law goes further in some aspects than similar bans passed by local cities. Belmont’s applies to residential units that share a floor or ceiling but not those with only adjacent walls between them, said Karen Licavoli, chairwoman of the San Mateo County Tobacco Education Foundation and vice president of programs for the nonprofit Breathe California. Daly City and Foster City’s laws do not apply to condominiums and townhomes.

In a related action, the supervisors amended existing county codes that prohibit smoking in public places to include electronic cigarettes as well as the tobacco products.

Email Bonnie Eslinger at beslinger@dailynewsgroup.com; follow her at twitter.com/bonnieeslinger.