This spring in New York City, clumps of homeless bees have turned up, often in inconvenient public places, at nearly double the rate of past years. A warm winter followed by an early spring, experts say, has created optimal breeding conditions. That may have caught some beekeepers off guard, especially those who have taken up the practice in recent years.
When Happy Miller, the Seaport restaurant manager, saw tourists flailing their arms in a cloud of airborne black specks late last month, he closed the glass door and quietly panicked. 
“Oh my God, what do I do?” he thought before calling 311, security guards and local news outfits.  The television trucks, he said, were first to arrive. It took several hours before Officer Anthony Planakis, the New York Police Department’s unofficial beekeeper in residence, arrived with a metal swarm box and a vacuum to collect the 17,500 or so homeless creatures.
Officer Planakis, who has been responding to swarm calls since 1995, said this had been New York’s busiest year of swarming he had ever experienced. Since mid-March, he said, he has tended to 31 jobs in the five boroughs, more than twice the number he handled last season, which is normally mid-April through July. “It’s been pretty hectic,” he said, adding that this week’s warmer temperatures could encourage more bees to take off.
This resurgence comes after several years of a puzzling decline in the honeybee population. Since 2006, beekeepers have reported that an average of 30 percent of their hiveshave vanished each year. The phenomenon — known as Colony Collapse Disorder — has prompted vigorous research to determine the cause, but has so far yieldedinconclusive and ambiguous results.
The swarms, while anxiety-provoking, have resulted in no major injuries.
It can be difficult to trace a swarm to its source. Officer Planakis said the bees he had collected were wild, but some beekeepers believe they were fleeing the poorly managed hives that have proliferated on rooftops, in backyards and on balconies since the city lifted a decade-long ban on raising Apis mellifera — the common, nonaggressive honeybee — in March 2010.
Since then, 114 people have registered 182 hives with the city’s Department of Health and Mental Hygiene. Many others say they are reluctant to divulge the location of their hives for fear of retribution from landlords, neighbors and the city. Some estimate the actual number of hives may be as high as 400. 
“There’s a stigma to a beekeeper whose hive swarms,” said Joe Langford, who watched from his kitchen window in Williamsburg, Brooklyn, on a Sunday in May as a 20-foot-high cloud of his bees blotted out the sun before landing on a nearby tree, to a few muffled screams below.  Before he could think about where to get a ladder, they had vanished.
“I was awe-struck and mortified at the same time,” he said.
While 311 will take complaints about bees, the New York City Beekeepers Association andNYCBeekeeping.org maintain swarm hot lines and may take the free bees.
This year’s unusually mild winter, the fourth warmest on record, may have allowed more bees to survive. Flowering plants and trees began blossoming several weeks early, causing colonies to peak early. In the spring, a colony can explode tenfold to take in nectar. The early arrival could have caught beekeepers off guard; if they failed to add enough space, the bees would follow a queen in search of a roomier hollow to call home.
“This year, all the rules were broken,” said Dennis vanEngelsdorp, a researcher at the University of Maryland who helped to lead a national survey of managed honey bee colonies released this month. It showed that about 21.9 percent of bee colonies nationwide died over the winter, a substantial drop from the 30 percent average losses reported in the previous five years.
When asked if this meant a rebound in the population, Mr. vanEngelsdorp said on Skype from Pretoria, South Africa, “It’s too early to tell.”
The state’s Agriculture Department estimates there are 60,000 to 70,000 colonies in New York. And the state’s 17 or so beekeeping clubs have generally doubled in size in the last five years, said Paul Cappy, the head apiculturist for the Agriculture Department’s Apiary Inspection Program.
A swarm is a perfectly natural phenomenon, Mr. Cappy said; “It’s good for the bee population, but not for the beekeepers.”
Defenders of the humble insect are quick to point out that when swarming, honeybees tend to be docile, and are unlikely to sting.
“It’s up to beekeepers to practice swarm prevention techniques and regular hive maintenance,” said Andrew Coté, the president and founder of the New York City Beekeepers Association, adding that many beekeepers were “poor stewards” for not regularly inspecting their hives. “If they treated their dog or cat in the same way, they would be taken up on charges,” he said.
Beekeepers should tend to their hives every 7 to 10 days depending on the weather to check for diseases and a healthy laying queen, along with signs of swarming, Mr. Coté said. Swarming, usually brought on by overcrowding or poor ventilation, does not occur without specific telltale signs, he said, like queen cells being built to prepare the colony for the new monarch.
Mr. Coté advocates stricter regulations. “But you can’t regulate common sense,” he added.
Dr. Waheed Bajwa, the executive director of the city health department’s Office of Vector Surveillance and Control, said he believed that the city’s beekeepers were adequately managing their hives this season and that the department was doing its best to keep up with the influx of rooftop and backyard beekeepers.
“This is something new for New York City,” he said, adding that the department was not planning to change its policies. “If we need to make any adjustment in the future, we will. But at this time, we don’t see there’s any need.”
On the northern edge of the Brooklyn Navy Yard, Chase Emmons, a managing partner ofBrooklyn Grange Rooftop Farm, was prepared.  He set up bait hives and added a product that mixes queen pheromones and lemon grass oil to nearby trees to lure the queen and her swarm to nearby locations.
Two weeks ago, he was standing in the slow-moving cloud when it took off.  It was like diving with sharks, he said.
“They’re not aggressive,” he said. “There’s a weird vibe where they have no interest in you.”
Mr. Emmons, who has organized a yearlong apprenticeship program with a dozen aspiring beekeepers as part of the apiary, acknowledged bee guardians had had to stay on their toes.  But there is an upside.
“City folk should be happy that we’re getting early-season honey,” he said.