The New York City Council voted on Wednesday to ban natural gas in new buildings, following in the footsteps of dozens of smaller US cities seeking to shift from fossil fuels to cleaner forms of energy.