The first comprehensive study of energy use by New York City’s largest buildings shows some to be power hogs, using up to five times as much electricity, natural gas, heating oil and steam as others of comparable size or purpose. And there is ample room for improvement.

The report, to be released on Friday by the city’s Office of Long-Term Planning and Sustainability, estimates that if poor-performing buildings in the city improved their efficiency and reached just the median level of energy use in their categories, the city’s energy consumption would decline by at least 18 percent and greenhouse gas emissions would be cut by 24 percent.

The Bloomberg administration deems such an improvement to be crucial to the city’s effort to reduce emissions associated with global warming: buildings, their heating and cooling especially, account for two-thirds of those emissions in the city.

But while lowering their utility bills gives building owners a major incentive to make energy upgrades, the initial costs have been a deterrent, and intense opposition from owners has staved off new city laws requiring some upgrades and retrofits.